简体   繁体   English

JQuery.Dirty字段不适用于第一个“ updateFormState”,但适用于第二个

[英]JQuery.Dirty Fields not work on first `updateFormState` but work on second

Using jquery.dirtyFields for updating form state on button click. 使用jquery.dirtyFields单击按钮时更新表单状态。 It worked fine on button click which passes through following code 在通过以下代码的按钮单击上效果很好

$('#hidChangeBox').val(true);
$.fn.dirtyFields.updateFormState($("#formId"));

But it does not work fine first time on button Click. 但是,第一次单击按钮时,它不能正常工作。 Could anyone suggest what reason it could be? 谁能说出原因呢?

Following Link for reference: http://www.thoughtdelimited.org/dirtyFields/documentation.cfm 以下链接供参考: http : //www.thoughtdelimited.org/dirtyFields/documentation.cfm

Could it be the type of field? 可能是字段类型吗? The library doesn't seem to be aware of the new field types in HTML5. 该库似乎没有意识到HTML5中的新字段类型。 ie input[type='number'] 即input [type ='number']

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM