EasyUI Forum
May 16, 2024, 12:28:43 PM *
Welcome, Guest. Please login or register.

Login with username, password and session length
News:
 
   Home   Help Search Login Register  
Pages: [1]
  Print  
Author Topic: form onchange not firing  (Read 10090 times)
devnull
Sr. Member
****
Posts: 431


View Profile
« on: March 13, 2013, 05:41:45 AM »

can't get the form onchange event to fire with any of the easyui-boxes:

http://jsfiddle.net/uAqKG/1

only the normal <input type="text"> appears to fire the onchange event.



Logged

-- Licensed User --
devnull
Sr. Member
****
Posts: 431


View Profile
« Reply #1 on: March 14, 2013, 04:09:36 PM »

Bump...

Any solution for this Huh
Logged

-- Licensed User --
stworthy
Administrator
Hero Member
*****
Posts: 3581


View Profile Email
« Reply #2 on: March 14, 2013, 05:57:32 PM »

Here is the solution to solve this problem.
Code:
(function($){
var datebox = $.fn.datebox.defaults.onChange;
$.fn.datebox.defaults.onChange = function(newValue, oldValue){
$(this).closest('form').trigger('change');
datebox.call(this, newValue, oldValue);
};
var combobox = $.fn.combobox.defaults.onChange;
$.fn.combobox.defaults.onChange = function(newValue, oldValue){
$(this).closest('form').trigger('change');
combobox.call(this, newValue, oldValue);
};
})(jQuery);

Please refer to the updated sample http://jsfiddle.net/uAqKG/4/.
Logged
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines Valid XHTML 1.0! Valid CSS!