[Vtigercrm-commits] [vtiger-commits] r4330 - /vtigercrm/trunk/modules/CustomView/EditView.php

vtigercrm-commits at vtiger.fosslabs.com vtigercrm-commits at vtiger.fosslabs.com
Mon Mar 20 05:56:51 EST 2006


Author: saraj
Date: Mon Mar 20 03:56:47 2006
New Revision: 4330

Log:
array has been constructed in getStdFilterHTML function

Modified:
    vtigercrm/trunk/modules/CustomView/EditView.php

Modified: vtigercrm/trunk/modules/CustomView/EditView.php
==============================================================================
--- vtigercrm/trunk/modules/CustomView/EditView.php (original)
+++ vtigercrm/trunk/modules/CustomView/EditView.php Mon Mar 20 03:56:47 2006
@@ -112,8 +112,8 @@
         {
                 $advfilterhtml = getAdvCriteriaHTML($advfilterlist[$i-1]["comparator"]);
 		$advcolumnhtml = getByModule_ColumnsHTML($cv_module,$modulecollist,$advfilterlist[$i-1]["columnname"]);
-		$smarty->assign("FOPTION".$i,$advfilterhtml);
-                $smarty->assign("BLOCK".$i,$advcolumnhtml);
+		$smarty->assign("FOPTION",$advfilterhtml);
+                $smarty->assign("BLOCK",$advcolumnhtml);
 		$smarty->assign("VALUE".$i,$advfilterlist[$i-1]["value"]);
         }
 
@@ -194,6 +194,7 @@
 {
         global $app_list_strings;
         global $oCustomView;
+	$stdfilter = array();
         $result = $oCustomView->getStdCriteriaByModule($module);
 	$mod_strings = return_module_language($current_language,$module);
 
@@ -205,26 +206,34 @@
 			{
 			if($key == $selected)
                         {
-                        $shtml .= "<option selected value=\"".$key."\">".$app_list_strings['moduleList'][$module]." - ".$mod_strings[$value]."</option>";
+				$filter['value'] = $key;
+				$filter['text'] = $app_list_strings['moduleList'][$module]." - ".$mod_strings[$value];
+				$filter['selected'] = "selected";
                         }else
                         {
-                        $shtml .= "<option value=\"".$key."\">".$app_list_strings['moduleList'][$module]." - ".$mod_strings[$value]."</option>";
+				$filter['value'] = $key;
+				$filter['text'] = $app_list_strings['moduleList'][$module]." - ".$mod_strings[$value];
+				$filter['selected'] ="";
                         }
 			}else
 			{
 			if($key == $selected)
                         {
-                   	$shtml .= "<option selected value=\"".$key."\">".$app_list_strings['moduleList'][$module]." - ".$value."</option>";
+				$filter['value'] = $key;
+				$filter['text'] = $app_list_strings['moduleList'][$module]." - ".$value;
+				$filter['selected'] = 'selected';
                         }else
                         {
-                        $shtml .= "<option value=\"".$key."\">".$app_list_strings['moduleList'][$module]." - ".$value."</opt
-ion>";
+				$filter['value'] = $key;
+				$filter['text'] = $app_list_strings['moduleList'][$module]." - ".$value;
+				$filter['selected'] ='';
                         }
 			}
+			$stdfilter[]=$filter;
                 }
         }
 
-        return $shtml;
+        return $stdfilter;
 }
 //step3
 





More information about the vtigercrm-commits mailing list