[IMP] added arguments to widget html
bzr revid: nicolas.vanhoren@openerp.com-20120910135747-azld1lovg6d7w23c
This commit is contained in:
parent
1c0dd3b016
commit
8126882b0e
|
@ -2398,6 +2398,13 @@ instance.web.form.FieldText = instance.web.form.AbstractField.extend(instance.we
|
|||
*/
|
||||
instance.web.form.FieldTextHtml = instance.web.form.AbstractField.extend(instance.web.form.ReinitializeFieldMixin, {
|
||||
template: 'FieldTextHtml',
|
||||
init: function() {
|
||||
this._super.apply(this, arguments);
|
||||
if (this.field.type !== 'html' && ! this.options.safe) {
|
||||
throw new Error(_.str.sprintf(
|
||||
_t("Error with field %s, it is not allowed to use the widget 'html' with any other field type than 'html'"), this.string));
|
||||
}
|
||||
},
|
||||
initialize_content: function() {
|
||||
var self = this;
|
||||
if (! this.get("effective_readonly")) {
|
||||
|
|
Loading…
Reference in New Issue