[FIX] mass_mailing: ensure design element changes are applied

When we change something in the DESIGN tab of mass_mailing, we edit a
stylesheet. This means we need to flush the rules cache so
convert_inline applies the new rules in its conversion.

opw-3114599

closes odoo/odoo#111778

X-original-commit: 4ebf106e65ae4901c03c76606a05d8cd2e0790d7
Signed-off-by: David Monjoie (dmo) <dmo@odoo.com>
This commit is contained in:
Antoine Guenet
2023-02-03 10:35:53 +01:00
parent 8a6337f15b
commit 40494b807d
@@ -220,6 +220,9 @@ options.registry.DesignTab = options.Class.extend({
cssTexts.push(rule.cssText);
}
this.styleElement.textContent = cssTexts.join('\n');
// Flush the rules cache for convert_inline, to make sure they are
// recomputed to account for the change.
this.options.wysiwyg._rulesCache = undefined;
},
/**
* @override