From 887385aeb613be2ff46d1c77652a28b253f80cbb Mon Sep 17 00:00:00 2001 From: satish <satish.dvnk@vtiger.com> Date: Thu, 1 Jun 2017 15:57:50 +0530 Subject: [PATCH] Fixes #549 - vt7: jQuery validation error reported --- layouts/v7/modules/Vtiger/resources/validation.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/layouts/v7/modules/Vtiger/resources/validation.js b/layouts/v7/modules/Vtiger/resources/validation.js index 97e3ef2cb..c2e44ee37 100644 --- a/layouts/v7/modules/Vtiger/resources/validation.js +++ b/layouts/v7/modules/Vtiger/resources/validation.js @@ -184,7 +184,8 @@ jQuery.validator.addMethod("greaterThanDependentField", function(value, element, if(typeof sourceFieldInfo == 'undefined' || typeof depFieldInfo == 'undefined') 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'); return result; } -- GitLab