diff --git a/application/Espo/Resources/layouts/Email/detail.json b/application/Espo/Resources/layouts/Email/detail.json index 489b07ebeb..9bd7acbc0a 100644 --- a/application/Espo/Resources/layouts/Email/detail.json +++ b/application/Espo/Resources/layouts/Email/detail.json @@ -3,8 +3,8 @@ "label":"", "rows":[ [{"name":"dateSent"},{"name":"from"}], - [false, {"name":"to"}], - [{"name":"parent"}, {"name":"cc"}], + [{"name":"parent"}, {"name":"to"}], + [false, {"name":"cc"}], [false, {"name":"bcc"}], [{"name":"subject","fullWidth":true}], [{"name":"body","fullWidth":true}], diff --git a/application/Espo/Resources/layouts/Email/detailRestricted.json b/application/Espo/Resources/layouts/Email/detailRestricted.json index 5b98ce0492..dba2aa2981 100644 --- a/application/Espo/Resources/layouts/Email/detailRestricted.json +++ b/application/Espo/Resources/layouts/Email/detailRestricted.json @@ -3,8 +3,8 @@ "label":"", "rows":[ [{"name":"dateSent", "readOnly": true},{"name":"from", "readOnly": true}], - [false, {"name":"to", "readOnly": true}], - [{"name":"parent"}, {"name":"cc", "readOnly": true}], + [{"name":"parent"}, {"name":"to", "readOnly": true}], + [false, {"name":"cc", "readOnly": true}], [false, {"name":"bcc", "readOnly": true}], [{"name":"body","fullWidth":true, "readOnly": true, "customLabel": ""}], [{"name":"attachments", "readOnly": true, "fullWidth":true, "customLabel": ""}] diff --git a/client/src/views/email/record/edit.js b/client/src/views/email/record/edit.js index f185a259c4..d20f5a416e 100644 --- a/client/src/views/email/record/edit.js +++ b/client/src/views/email/record/edit.js @@ -82,7 +82,7 @@ define('views/email/record/edit', ['views/record/edit', 'views/email/record/deta }, handleCcField: function () { - if (!this.model.get('cc')) { + if (!this.model.get('cc') && this.model.get('status') !== 'Draft') { this.hideField('cc'); } else { this.showField('cc'); @@ -90,7 +90,7 @@ define('views/email/record/edit', ['views/record/edit', 'views/email/record/deta }, handleBccField: function () { - if (!this.model.get('bcc')) { + if (!this.model.get('bcc') && this.model.get('status') !== 'Draft') { this.hideField('bcc'); } else { this.showField('bcc');