[Vtigercrm-commits] [vtiger-commits] r10755 - in /vtigercrm/branches/5.0.3/include: language/en_us.lang.php utils/SearchUtils.php
vtigercrm-commits at vtiger.fosslabs.com
vtigercrm-commits at vtiger.fosslabs.com
Sun Apr 22 13:03:44 EDT 2007
Author: saraj
Date: Sun Apr 22 11:03:36 2007
New Revision: 10755
Log:
In Basic Search of Notes,Searching contact with full name gives empty result. Fixes #3301
Modified:
vtigercrm/branches/5.0.3/include/language/en_us.lang.php
vtigercrm/branches/5.0.3/include/utils/SearchUtils.php
Modified: vtigercrm/branches/5.0.3/include/language/en_us.lang.php
==============================================================================
--- vtigercrm/branches/5.0.3/include/language/en_us.lang.php (original)
+++ vtigercrm/branches/5.0.3/include/language/en_us.lang.php Sun Apr 22 11:03:36 2007
@@ -872,6 +872,7 @@
'Lead Status'=>'Lead Status',
'Lead Source'=>'Lead Source',
'Quote ID'=>'Quote Id',
+'LBL_CONTACT_LAST_NAME'=>'Contact - Last Name',
);
$app_list_strings = array (
Modified: vtigercrm/branches/5.0.3/include/utils/SearchUtils.php
==============================================================================
--- vtigercrm/branches/5.0.3/include/utils/SearchUtils.php (original)
+++ vtigercrm/branches/5.0.3/include/utils/SearchUtils.php Sun Apr 22 11:03:36 2007
@@ -129,7 +129,8 @@
if($fieldname!='parent_id')
{
$fld_name=$fieldname;
-
+ if($fieldname == 'contact_id')
+ $name = $app_strings['LBL_CONTACT_LAST_NAME'];
//assign the translated string
$search_header[$fld_name] = getTranslatedString($name);
}
@@ -306,6 +307,12 @@
}
//Check ends
+ if($module == "Notes" && $search_field == "contact_id")
+ {
+ $module = 'Contacts';
+ $search_field = 'lastname';
+ }
+
$qry="select vtiger_field.columnname,tablename from vtiger_tab inner join vtiger_field on vtiger_field.tabid=vtiger_tab.tabid where name='".$module."' and (fieldname='".$search_field."' or columnname='".$search_field."')";
$result = $adb->query($qry);
$noofrows = $adb->num_rows($result);
More information about the vtigercrm-commits
mailing list