diff --git a/client/modules/crm/src/knowledge-base-helper.js b/client/modules/crm/src/knowledge-base-helper.js index ca01caeeb0..7e4f115571 100644 --- a/client/modules/crm/src/knowledge-base-helper.js +++ b/client/modules/crm/src/knowledge-base-helper.js @@ -41,7 +41,12 @@ Espo.define('crm:knowledge-base-helper', 'ajax', function (Ajax) { getAttributesForEmail: function (model, attributes, callback) { attributes = attributes || {}; attributes.body = model.get('body'); - attributes.name = this.getLanguage().translate('KnowledgeBaseArticle', 'scopeNames') + ': ' + model.get('name'); + if (attributes.name) { + attributes.name = attributes.name + ' '; + } else { + attributes.name = ''; + } + attributes.name += this.getLanguage().translate('KnowledgeBaseArticle', 'scopeNames') + ': ' + model.get('name'); Ajax.postRequest('KnowledgeBaseArticle/action/getCopiedAttachments', { id: model.id diff --git a/client/modules/crm/src/views/case/record/panels/activities.js b/client/modules/crm/src/views/case/record/panels/activities.js index 096f5bcca7..17d8f5a908 100644 --- a/client/modules/crm/src/views/case/record/panels/activities.js +++ b/client/modules/crm/src/views/case/record/panels/activities.js @@ -94,30 +94,6 @@ Espo.define('crm:views/case/record/panels/activities', 'crm:views/record/panels/ callback.call(this, attributes); }.bind(this)); - - /*if (this.model.get('contactId')) { - this.getModelFactory().create('Contact', function (contact) { - contact.id = this.model.get('contactId'); - - this.listenToOnce(contact, 'sync', function () { - var emailAddress = contact.get('emailAddress'); - if (emailAddress) { - attributes.to = emailAddress; - attributes.nameHash = {}; - attributes.nameHash[emailAddress] = contact.get('name'); - } - - callback.call(this, attributes); - }); - contact.fetch({ - error: function () { - callback.call(this, attributes); - }.bind(this) - }); - }, this); - } else { - callback.call(this, attributes); - }*/ } }); }); diff --git a/client/modules/crm/src/views/knowledge-base-article/record/list-for-case.js b/client/modules/crm/src/views/knowledge-base-article/record/list-for-case.js index 3fd1a836c3..975095c83e 100644 --- a/client/modules/crm/src/views/knowledge-base-article/record/list-for-case.js +++ b/client/modules/crm/src/views/knowledge-base-article/record/list-for-case.js @@ -74,7 +74,8 @@ Espo.define('crm:views/knowledge-base-article/record/list-for-case', 'views/reco var attributes = { parentType: 'Case', parentId: parentModel.id, - parentName: parentModel.get('name') + parentName: parentModel.get('name'), + name: '[#' + parentModel.get('number') + ']' }; attributes.to = '';