mirror of
https://github.com/espocrm/espocrm.git
synced 2026-06-30 07:56:05 +00:00
email template status
This commit is contained in:
@@ -29,6 +29,7 @@
|
||||
|
||||
namespace Espo\Classes\Select\EmailTemplate\PrimaryFilters;
|
||||
|
||||
use Espo\Entities\EmailTemplate;
|
||||
use Espo\ORM\Query\SelectBuilder;
|
||||
|
||||
use Espo\Core\Select\Primary\Filter;
|
||||
@@ -38,7 +39,8 @@ class Actual implements Filter
|
||||
public function apply(SelectBuilder $queryBuilder): void
|
||||
{
|
||||
$queryBuilder->where([
|
||||
'oneOff!=' => true
|
||||
'oneOff!=' => true,
|
||||
'status' => EmailTemplate::STATUS_ACTIVE,
|
||||
]);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -36,6 +36,8 @@ class EmailTemplate extends Entity
|
||||
{
|
||||
public const ENTITY_TYPE = 'EmailTemplate';
|
||||
|
||||
public const STATUS_ACTIVE = 'Active';
|
||||
|
||||
public function getSubject(): ?string
|
||||
{
|
||||
return $this->get('subject');
|
||||
|
||||
@@ -17,6 +17,12 @@
|
||||
"Info": "Info",
|
||||
"Available placeholders": "Available placeholders"
|
||||
},
|
||||
"options": {
|
||||
"status": {
|
||||
"Active": "Active",
|
||||
"Inactive": "Inactive"
|
||||
}
|
||||
},
|
||||
"messages": {
|
||||
"infoText": "Available placeholders:\n\n{optOutUrl} – URL for an unsubscribe link;\n\n{optOutLink} – an unsubscribe link."
|
||||
},
|
||||
|
||||
@@ -1,31 +1,35 @@
|
||||
[
|
||||
{
|
||||
"label":"",
|
||||
"rows":[
|
||||
[
|
||||
{
|
||||
"name":"name"
|
||||
"name": "name"
|
||||
},
|
||||
{
|
||||
"name":"oneOff"
|
||||
"name": "status"
|
||||
}
|
||||
],
|
||||
[
|
||||
{
|
||||
"name": "category"
|
||||
},
|
||||
false
|
||||
],
|
||||
[{"name":"subject","fullWidth":true}],
|
||||
[
|
||||
{
|
||||
"name":"insertField",
|
||||
"view": "views/email-template/fields/insert-field",
|
||||
"fullWidth":true
|
||||
"name": "oneOff"
|
||||
}
|
||||
],
|
||||
[{"name":"body","fullWidth":true}],
|
||||
[{"name":"attachments"},{"name":"isHtml"}]
|
||||
[
|
||||
{
|
||||
"name": "subject"
|
||||
}
|
||||
],
|
||||
[
|
||||
{
|
||||
"name": "insertField",
|
||||
"view": "views/email-template/fields/insert-field"
|
||||
}
|
||||
],
|
||||
[{"name": "body"}],
|
||||
[{"name": "attachments"}, {"name":"isHtml"}]
|
||||
]
|
||||
}
|
||||
]
|
||||
|
||||
@@ -1,19 +1,17 @@
|
||||
[
|
||||
{
|
||||
"label":"",
|
||||
"rows":[
|
||||
[{"name": "name"}, {"name":"oneOff"}],
|
||||
[{"name": "category"}, false],
|
||||
[{"name":"subject","fullWidth": true}],
|
||||
[{"name": "name"}, {"name": "status"}],
|
||||
[{"name": "category"}, {"name": "oneOff"}],
|
||||
[{"name": "subject"}],
|
||||
[
|
||||
{
|
||||
"name":"insertField",
|
||||
"view": "views/email-template/fields/insert-field",
|
||||
"fullWidth":true
|
||||
"name": "insertField",
|
||||
"view": "views/email-template/fields/insert-field"
|
||||
}
|
||||
],
|
||||
[{"name":"body","fullWidth": true}],
|
||||
[{"name":"attachments"},{"name":"isHtml"}]
|
||||
[{"name": "body"}],
|
||||
[{"name": "attachments"}, {"name": "isHtml"}]
|
||||
]
|
||||
}
|
||||
]
|
||||
|
||||
@@ -7,6 +7,10 @@
|
||||
"name": "assignedUser",
|
||||
"width": 20
|
||||
},
|
||||
{
|
||||
"name": "status",
|
||||
"width": 13
|
||||
},
|
||||
{
|
||||
"name": "oneOff",
|
||||
"width": 11,
|
||||
@@ -14,7 +18,7 @@
|
||||
},
|
||||
{
|
||||
"name": "createdAt",
|
||||
"width": 20,
|
||||
"width": 18,
|
||||
"hidden": true
|
||||
}
|
||||
]
|
||||
|
||||
@@ -18,6 +18,18 @@
|
||||
"default": true,
|
||||
"inlineEditDisabled": true
|
||||
},
|
||||
"status": {
|
||||
"type": "enum",
|
||||
"options": [
|
||||
"Active",
|
||||
"Inactive"
|
||||
],
|
||||
"default": "Active",
|
||||
"style": {
|
||||
"Inactive": "info"
|
||||
},
|
||||
"maxLength": 8
|
||||
},
|
||||
"oneOff": {
|
||||
"type": "bool",
|
||||
"default": false,
|
||||
|
||||
Reference in New Issue
Block a user