Files
x-editable/src/editable-form/editable-form-bootstrap.js
2013-04-11 23:40:05 +04:00

22 lines
772 B
JavaScript

/*
Editableform based on Twitter Bootstrap
*/
(function ($) {
"use strict";
$.extend($.fn.editableform.Constructor.prototype, {
initTemplate: function() {
this.$form = $($.fn.editableform.template);
this.$form.find('.editable-error-block').addClass('help-block');
}
});
//buttons
$.fn.editableform.buttons = '<button type="submit" class="btn btn-primary editable-submit"><i class="icon-ok icon-white"></i></button>'+
'<button type="button" class="btn editable-cancel"><i class="icon-remove"></i></button>';
//error classes
$.fn.editableform.errorGroupClass = 'error';
$.fn.editableform.errorBlockClass = null;
}(window.jQuery));