Skip to content
Snippets Groups Projects
Commit 2eeab71c authored by divy-odoo's avatar divy-odoo
Browse files

[FIX] website_blog: fix size options values when blog regular cover


Before this commit, the widget value was updated (based on the current
state) prior to updating the snippet UI. As a result, the widget value
reflected used the non-updated UI labels.

task-3112890

closes odoo/odoo#122279

X-original-commit: b2daf688
Signed-off-by: default avatarQuentin Smetz (qsm) <qsm@odoo.com>
Signed-off-by: default avatarDivyesh Vyas (divy) <divy@odoo.com>
parent 955813bf
No related branches found
No related tags found
No related merge requests found
......@@ -44,7 +44,6 @@ options.registry.CoverProperties.include({
* @override
*/
updateUI: async function () {
await this._super(...arguments);
var isRegularCover = this.$target.is('.o_wblog_post_page_cover_regular');
var $coverFull = this.$el.find('[data-select-class*="o_full_screen_height"]');
var $coverMid = this.$el.find('[data-select-class*="o_half_screen_height"]');
......@@ -55,6 +54,7 @@ options.registry.CoverProperties.include({
$coverFull.children('div').text(isRegularCover ? _t("Large") : this._coverFullOriginalLabel);
$coverMid.children('div').text(isRegularCover ? _t("Medium") : this._coverMidOriginalLabel);
$coverAuto.children('div').text(isRegularCover ? _t("Tiny") : this._coverAutoOriginalLabel);
return this._super(...arguments);
},
});
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment