[Vtigercrm-commits] [vtiger-commits] r6823 - /vtigercrm/trunk/modules/Calendar/script.js
vtigercrm-commits at vtiger.fosslabs.com
vtigercrm-commits at vtiger.fosslabs.com
Wed May 31 03:10:16 EDT 2006
Author: saraj
Date: Wed May 31 01:10:12 2006
New Revision: 6823
Log:
changes made to fix validation issue in calendar events
Modified:
vtigercrm/trunk/modules/Calendar/script.js
Modified: vtigercrm/trunk/modules/Calendar/script.js
==============================================================================
--- vtigercrm/trunk/modules/Calendar/script.js (original)
+++ vtigercrm/trunk/modules/Calendar/script.js Wed May 31 01:10:12 2006
@@ -204,7 +204,10 @@
{
if(startformat == 'pm')
{
- starthour = eval(starthour) + 12;
+ if(starthour == '12')
+ starthour = 12;
+ else
+ starthour = eval(starthour) + 12;
startmin = startmin;
}
else
@@ -217,7 +220,10 @@
{
if(endformat == 'pm')
{
- endhour = eval(endhour) + 12;
+ if(endhour == '12')
+ endhour = 12;
+ else
+ endhour = eval(endhour) + 12;
endmin = endmin;
}
else
@@ -226,13 +232,17 @@
endmin = endmin;
}
}
- if((eval(endhour)*60+eval(endmin)) < (eval(starthour)*60+eval(startmin)))
- {
- alert("End Time should be greater than Start Time ");
- document.appSave.endhr.focus();
- return false;
- }
-
+ if(dateComparison('due_date','End date','date_start','Start date','GE'))
+ {
+ if((eval(endhour)*60+eval(endmin)) < (eval(starthour)*60+eval(startmin)))
+ {
+ alert("End Time should be greater than Start Time ");
+ document.appSave.endhr.focus();
+ return false;
+ }
+ }
+ else
+ return false;
durationinmin = (eval(endhour)*60+eval(endmin)) - (eval(starthour)*60+eval(startmin));
if(durationinmin >= 60)
{
More information about the vtigercrm-commits
mailing list