Migration of web_widget_color to 10.0 (#439)

[MIG] web_widget_color: Migration to 10.0
This commit is contained in:
Adrien Peiffer (ACSONE)
2016-10-12 10:54:45 +02:00
committed by Enric Tobella
parent f5bb54524e
commit 7cbe041756
3 changed files with 18 additions and 12 deletions

View File

@@ -61,7 +61,7 @@ odoo.define('web.web_widget_color', function(require) {
jscolor.init(this.$el[0]);
} else {
this.$(".oe_form_char_content").text(show_value);
this.$('div').css("background-color", show_value);
this.$('span').css("background-color", show_value);
}
}
});
@@ -72,7 +72,11 @@ odoo.define('web.web_widget_color', function(require) {
* Init jscolor for each editable mode on view form
*/
FormView.include({
to_edit_mode: function () {
on_button_edit: function () {
this._super();
jscolor.init(this.$el[0]);
},
on_button_create: function () {
this._super();
jscolor.init(this.$el[0]);
}