Skip to content
Snippets Groups Projects
Commit 887385ae authored by Satish's avatar Satish
Browse files

Fixes #549 - vt7: jQuery validation error reported

parent 339bb9a2
No related branches found
No related tags found
No related merge requests found
...@@ -184,7 +184,8 @@ jQuery.validator.addMethod("greaterThanDependentField", function(value, element, ...@@ -184,7 +184,8 @@ jQuery.validator.addMethod("greaterThanDependentField", function(value, element,
if(typeof sourceFieldInfo == 'undefined' || typeof depFieldInfo == 'undefined') if(typeof sourceFieldInfo == 'undefined' || typeof depFieldInfo == 'undefined')
return result; return result;
if(sourceFieldInfo.type !== 'date' || depFieldInfo.type !== 'date') { if((sourceFieldInfo.type !== 'date' || depFieldInfo.type !== 'date')
&& (sourceFieldInfo.type !== 'datetime' || depFieldInfo.type !== 'datetime')) { //start_date, end_date fields data type is datetime.
console.log('greaterThanDependentField() validation method should be used for date fields only'); console.log('greaterThanDependentField() validation method should be used for date fields only');
return result; return result;
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment