[Vtigercrm-commits] [vtiger-commits] r9337 - /vtigercrm/trunk/modules/Calendar/DetailView.php

vtigercrm-commits at vtiger.fosslabs.com vtigercrm-commits at vtiger.fosslabs.com
Thu Sep 7 03:57:25 EDT 2006


Author: saraj
Date: Thu Sep  7 01:57:19 2006
New Revision: 9337

Log:
changes made for weekly recurring events  --Minnie

Modified:
    vtigercrm/trunk/modules/Calendar/DetailView.php

Modified: vtigercrm/trunk/modules/Calendar/DetailView.php
==============================================================================
--- vtigercrm/trunk/modules/Calendar/DetailView.php (original)
+++ vtigercrm/trunk/modules/Calendar/DetailView.php Thu Sep  7 01:57:19 2006
@@ -174,7 +174,23 @@
 		$data['repeat_frequency'] = $adb->query_result($res,0,'recurringfreq');
 		$recurringinfo =  explode("::",$adb->query_result($res,0,'recurringinfo'));
 		$data['recurringtype'] = $recurringinfo[0];
-		if($recurringinfo[0] == 'Monthly')
+		if($recurringinfo[0] == 'Weekly')
+		{
+			$weekrpt_str = '';
+			if(count($recurringinfo) > 1)
+			{
+				$weekrpt_str .= 'on ';
+				for($i=1;$i<count($recurringinfo);$i++)
+				{
+					$label = 'LBL_DAY'.$recurringinfo[$i];
+					if($i != 1)
+						$weekrpt_str .= ', ';
+					$weekrpt_str .= $mod_strings[$label];
+				}
+			}
+			$data['repeat_str'] = $weekrpt_str;
+		}
+		elseif($recurringinfo[0] == 'Monthly')
 		{   
 			$monthrpt_str = '';
 			$data['repeatMonth'] = $recurringinfo[1];  
@@ -214,7 +230,7 @@
 
 				$monthrpt_str .= 'on '.$mod_strings[$recurringinfo[2]].' '.$day;
 			}
-			$data['repeat_month_str'] = $monthrpt_str;
+			$data['repeat_str'] = $monthrpt_str;
 		}
 	}
 	else 





More information about the vtigercrm-commits mailing list