[Vtigercrm-commits] [vtiger-commits] r9898 - /vtigercrm/branches/5.0.3/modules/CustomView/CustomView.php
vtigercrm-commits at vtiger.fosslabs.com
vtigercrm-commits at vtiger.fosslabs.com
Thu Nov 23 06:33:29 EST 2006
Author: richie
Date: Thu Nov 23 04:33:21 2006
New Revision: 9898
Log:
Salutaion type added in listview,customview
Modified:
vtigercrm/branches/5.0.3/modules/CustomView/CustomView.php
Modified: vtigercrm/branches/5.0.3/modules/CustomView/CustomView.php
==============================================================================
--- vtigercrm/branches/5.0.3/modules/CustomView/CustomView.php (original)
+++ vtigercrm/branches/5.0.3/modules/CustomView/CustomView.php Thu Nov 23 04:33:21 2006
@@ -186,20 +186,28 @@
$tabid = getTabid($module);
global $current_user;
require('user_privileges/user_privileges_'.$current_user->id.'.php');
+ if($tabid == 4 || $tabid ==7)
+ {
+ $display_type = " vtiger_field.displaytype in (1,2,3)";
+ }else
+ {
+ $display_type = " vtiger_field.displaytype in (1,2)";
+ }
if($is_admin == true || $profileGlobalPermission[1] == 0 || $profileGlobalPermission[2] == 0)
{
$sql = "select * from vtiger_field ";
$sql.= " where vtiger_field.tabid=".$tabid." and vtiger_field.block in (".$block.") and";
- $sql.= " vtiger_field.displaytype in (1,2)";
+ $sql.= $display_type;
$sql.= " order by sequence";
}
else
{
+
$profileList = getCurrentUserProfileList();
$sql = "select * from vtiger_field inner join vtiger_profile2field on vtiger_profile2field.fieldid=vtiger_field.fieldid inner join vtiger_def_org_field on vtiger_def_org_field.fieldid=vtiger_field.fieldid ";
$sql.= " where vtiger_field.tabid=".$tabid." and vtiger_field.block in (".$block.") and";
- $sql.= " vtiger_field.displaytype in (1,2) and vtiger_profile2field.visible=0";
+ $sql.= "$display_type and vtiger_profile2field.visible=0";
$sql.= " and vtiger_def_org_field.visible=0 and vtiger_profile2field.profileid in ".$profileList." order by sequence";
}
More information about the vtigercrm-commits
mailing list