init: function () {
var $this = this;
- $('#linkeditor-panel-form').on('change', '[name="type"]', function () {
+ $(document).on('change', '#linkeditor-panel-form [name="type"]', function () {
+ console.log('change type');
if ($this._maskChangeEvent) {
return;
}
$this.updateLinkForm();
});
- $('#linkeditor-panel-form').on('change', "input, select, textarea", function () {
+ $(document).on('change', "#linkeditor-panel-form input,#linkeditor-panel-form select,#linkeditor-panel-form textarea", function () {
if ($this._maskChangeEvent) {
return;
}
$(document).on('change', ".freefile-file-input", function () {
var form = $('#linkupload').clone();
-
var id = 'linkupload_' + Math.round(Math.random() * 10000000);
$(form).attr('id', id);
$(this).attr('form', id);
tf.val(data[0]);
tf.trigger('change');
$(parent).removeClass('loading');
+ $this.saveFormDataInLink();
setTimeout(function () {
$this.linkeditor.save.saveIfUnsavedChanges(TRANSLATIONS.upload_save_message, false, function () {
});
});
-
-
},
saveFormDataInLink: function () {