[Vtigercrm-commits] [vtiger-commits] r5129 - in /vtigercrm/trunk: include/utils/SearchUtils.php modules/Activities/ListView.php
vtigercrm-commits at vtiger.fosslabs.com
vtigercrm-commits at vtiger.fosslabs.com
Sat Apr 15 03:04:30 EDT 2006
Author: saraj
Date: Sat Apr 15 01:04:24 2006
New Revision: 5129
Log:
Changes made for advance Search
Modified:
vtigercrm/trunk/include/utils/SearchUtils.php
vtigercrm/trunk/modules/Activities/ListView.php
Modified: vtigercrm/trunk/include/utils/SearchUtils.php
==============================================================================
--- vtigercrm/trunk/include/utils/SearchUtils.php (original)
+++ vtigercrm/trunk/include/utils/SearchUtils.php Sat Apr 15 01:04:24 2006
@@ -161,11 +161,12 @@
}
}
//Added condition to hide the close column in Related Lists
- if($name == 'Close' && $relatedlist != '')
+ //if($name == 'Close' && $relatedlist != '')
+ if($name == 'Close')
{
//$list_header .= '';
// $list_header[] = '';
- }
+ }
else
{
$fld_name=$fieldname;
@@ -326,24 +327,25 @@
$result = $adb->query($sql);
$noofrows = $adb->num_rows($result);
$block = '';
- //Added on 14-10-2005 -- added ticket id in list
- if($module == 'HelpDesk' && $block == 25)
- {
- $module_columnlist['crmentity:crmid::HelpDesk_Ticket ID:I'] = 'Ticket ID';
- }
- //Added to include activity type in activity customview list
- if($module == 'Activities' && $block == 19)
- {
- $module_columnlist['activity:activitytype::Activities_Activity Type:C'] = 'Activity Type';
- }
-
+
for($i=0; $i<$noofrows; $i++)
{
$fieldtablename = $adb->query_result($result,$i,"tablename");
$fieldcolname = $adb->query_result($result,$i,"columnname");
+ $block = $adb->query_result($result,$i,"block");
$fieldtype = explode("~",$fieldtype);
$fieldtypeofdata = $fieldtype[0];
$fieldlabel = $adb->query_result($result,$i,"fieldlabel");
+ //Added on 14-10-2005 -- added ticket id in list
+ if($module == 'HelpDesk' && $block == 25)
+ {
+ $module_columnlist['crmentity:crmid::HelpDesk_Ticket ID:I'] = 'Ticket ID';
+ }
+ //Added to include activity type in activity customview list
+ if($module == 'Activities' && $block == 19)
+ {
+ $module_columnlist['activity:activitytype:activitytype:Activities_Activity Type:C'] = 'Activity Type';
+ }
if($fieldlabel == "Related To")
{
$fieldlabel = "Related to";
@@ -410,9 +412,9 @@
if(isset($_REQUEST['search_cnt']))
$tot_no_criteria = $_REQUEST['search_cnt'];
if($_REQUEST['matchtype'] == 'all')
+ $matchtype = "and";
+ else
$matchtype = "or";
- else
- $matchtype = "and";
for($i=0; $i<=$tot_no_criteria; $i++)
{
Modified: vtigercrm/trunk/modules/Activities/ListView.php
==============================================================================
--- vtigercrm/trunk/modules/Activities/ListView.php (original)
+++ vtigercrm/trunk/modules/Activities/ListView.php Sat Apr 15 01:04:24 2006
@@ -64,7 +64,7 @@
if(isset($_REQUEST['query']) && $_REQUEST['query'] == 'true')
{
- $where=Search($currentModule);
+ $where=getWhereCondition($currentModule);
// we have a query
$url_string .="&query=true";
@@ -177,6 +177,10 @@
$navigationOutput = getTableHeaderNavigation($navigation_array,$url_string,"Activities","index",$viewid);
$alphabetical = AlphabeticalSearch($currentModule,'index','subject','true','basic',"","","","",$viewid);
+$fieldnames = getAdvSearchfields($module);
+$criteria = getcriteria_options();
+$smarty->assign("CRITERIA", $criteria);
+$smarty->assign("FIELDNAMES", $fieldnames);
$smarty->assign("ALPHABETICAL", $alphabetical);
$smarty->assign("NAVIGATION", $navigationOutput);
$smarty->assign("RECORD_COUNTS", $record_string);
More information about the vtigercrm-commits
mailing list