do not set unsafe css when submit to user function, fixes

This commit is contained in:
vitalets 2012-11-20 11:31:42 +04:00
parent ec97af1d4b
commit 89ac2389c3

@ -277,8 +277,8 @@ Makes editable any HTML element on the page. Applied as jQuery method.
return; return;
} }
//if value was not sent to server and value changed --> mark element with unsaved css //if url is not user's function and value was not sent to server and value changed --> mark element with unsaved css.
if(params.response === undefined && this.input.value2str(this.value) !== this.input.value2str(params.newValue)) { if(typeof this.options.url !== 'function' && params.response === undefined && this.input.value2str(this.value) !== this.input.value2str(params.newValue)) {
this.$element.addClass('editable-unsaved'); this.$element.addClass('editable-unsaved');
} else { } else {
this.$element.removeClass('editable-unsaved'); this.$element.removeClass('editable-unsaved');