Save fontColor in the template
[MAILPOET-2278]
This commit is contained in:
committed by
Jack Kitterhing
parent
30b802f0c1
commit
6697424030
@ -5,7 +5,7 @@ import App from 'newsletter_editor/App';
|
|||||||
import BaseBlock from 'newsletter_editor/blocks/base';
|
import BaseBlock from 'newsletter_editor/blocks/base';
|
||||||
|
|
||||||
const BlockModel = BaseBlock.BlockModel.extend({
|
const BlockModel = BaseBlock.BlockModel.extend({
|
||||||
stale: ['styles'],
|
stale: ['styles.backgroundColor'],
|
||||||
defaults() {
|
defaults() {
|
||||||
return this._getDefaults({
|
return this._getDefaults({
|
||||||
type: 'woocommerceHeading',
|
type: 'woocommerceHeading',
|
||||||
|
@ -20,7 +20,7 @@ Module.save = function () {
|
|||||||
|
|
||||||
// Stringify to enable transmission of primitive non-string value types
|
// Stringify to enable transmission of primitive non-string value types
|
||||||
if (!_.isUndefined(json.body)) {
|
if (!_.isUndefined(json.body)) {
|
||||||
delete json.body.blockDefaults.woocommerceHeading;
|
delete json.body.blockDefaults.woocommerceHeading.styles.backgroundColor;
|
||||||
delete json.body.blockDefaults.woocommerceContent;
|
delete json.body.blockDefaults.woocommerceContent;
|
||||||
json.body = JSON.stringify(json.body);
|
json.body = JSON.stringify(json.body);
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user