@capillarytech/creatives-library 2.0.57 → 2.0.59
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -120,10 +120,11 @@ class Creatives extends React.Component {
|
|
|
120
120
|
const formData = {
|
|
121
121
|
subject: templateData.emailSubject,
|
|
122
122
|
html_content: templateData.emailBody,
|
|
123
|
-
is_drag_drop:
|
|
124
|
-
lang_id:
|
|
125
|
-
iso_code:
|
|
126
|
-
language:
|
|
123
|
+
is_drag_drop: templateData.is_drag_drop,
|
|
124
|
+
lang_id: templateData.lang_id,
|
|
125
|
+
iso_code: templateData.iso_code,
|
|
126
|
+
language: templateData.language,
|
|
127
|
+
drag_drop_id: templateData.drag_drop_id,
|
|
127
128
|
};
|
|
128
129
|
creativesTeplateData = {
|
|
129
130
|
base: formData,
|
|
@@ -158,12 +159,14 @@ class Creatives extends React.Component {
|
|
|
158
159
|
}
|
|
159
160
|
|
|
160
161
|
getCreativesData = (channel, template) => { //from creatives to consumers
|
|
161
|
-
|
|
162
|
+
let templateData = {channel };
|
|
162
163
|
if (channel === constants.SMS && template.value.base) {
|
|
163
164
|
templateData.messageBody = template.value.base['sms-editor'];
|
|
164
165
|
} else if (channel === constants.EMAIL && template.value.base) {
|
|
165
|
-
|
|
166
|
-
templateData
|
|
166
|
+
const emailBase = template.value.base;
|
|
167
|
+
templateData = {...templateData, ...emailBase, emailBody: emailBase.html_content, emailSubject: emailBase.subject};
|
|
168
|
+
delete templateData.html_content;
|
|
169
|
+
delete templateData.subject;
|
|
167
170
|
} else if (channel === constants.MOBILE_PUSH && get(template, "value.versions.base")) {
|
|
168
171
|
const mobilpushTemplate = template.value;
|
|
169
172
|
templateData.accountId = get(mobilpushTemplate, 'definition.accountId');
|
|
@@ -53,7 +53,7 @@ export class TemplatesV2 extends React.Component { // eslint-disable-line react/
|
|
|
53
53
|
const deafaultPanes = [
|
|
54
54
|
{content: <div></div>, tab: 'Sms', key: 'sms'},
|
|
55
55
|
{content: <div></div>, tab: 'Email', key: 'email'},
|
|
56
|
-
|
|
56
|
+
{content: <div></div>, tab: 'Call Task', key: 'calltask'},
|
|
57
57
|
// {content: this.getTemplatesComponent('wechat'), tab: 'Wechat', key: 'wechat'},
|
|
58
58
|
{content: <div></div>, tab: 'Mpush', key: 'mobilepush'},
|
|
59
59
|
];
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@capillarytech/creatives-library",
|
|
3
3
|
"author": "meharaj",
|
|
4
|
-
"version": "2.0.
|
|
4
|
+
"version": "2.0.59",
|
|
5
5
|
"description": "Capillary creatives ui",
|
|
6
6
|
"main": "./index.js",
|
|
7
7
|
"module": "./index.es.js",
|
|
@@ -12,8 +12,8 @@
|
|
|
12
12
|
},
|
|
13
13
|
"license": "LicenseRef-LICENSE",
|
|
14
14
|
"dependencies": {
|
|
15
|
-
"@capillarytech/cap-ui-library": "^1.0.
|
|
16
|
-
"antd": "
|
|
15
|
+
"@capillarytech/cap-ui-library": "^1.0.100",
|
|
16
|
+
"antd": "3.15.0",
|
|
17
17
|
"axios": "^0.16.2",
|
|
18
18
|
"babel-polyfill": "6.20.0",
|
|
19
19
|
"babel-preset-env": "^1.6.1",
|