[Vtigercrm-commits] [vtiger-commits] r5902 - /vtigercrm/trunk/include/utils/UserInfoUtil.php
vtigercrm-commits at vtiger.fosslabs.com
vtigercrm-commits at vtiger.fosslabs.com
Fri May 12 05:58:55 EDT 2006
Author: don
Date: Fri May 12 03:58:51 2006
New Revision: 5902
Log:
Modified Campaigns security list query
Modified:
vtigercrm/trunk/include/utils/UserInfoUtil.php
Modified: vtigercrm/trunk/include/utils/UserInfoUtil.php
==============================================================================
--- vtigercrm/trunk/include/utils/UserInfoUtil.php (original)
+++ vtigercrm/trunk/include/utils/UserInfoUtil.php Fri May 12 03:58:51 2006
@@ -4343,12 +4343,16 @@
}
elseif($module == 'Campaigns')
{
- $sec_query .= "and (crmentity.smownerid in($current_user->id) or crmentity.smownerid in(select user2role.userid from user2role inner join users on users.id=user2role.userid inner join role on role.roleid=user2role.roleid where role.parentrole like '".$current_user_parent_role_seq."::%')";
-
- if(sizeof($current_user_groups) > 0)
- {
- $sec_query .= " or (crmentity.smownerid in (0) and (groups.groupid in".getCurrentUserGroupList()."))) ";
- }
+
+ $sec_query .= " and (crmentity.smownerid in($current_user->id) or crmentity.smownerid in(select user2role.userid from user2role inner join users on users.id=user2role.userid inner join role on role.roleid=user2role.roleid where role.parentrole like '".$current_user_parent_role_seq."::%') or crmentity.smownerid in(select shareduserid from tmp_read_user_sharing_per where userid=".$current_user->id." and tabid=".$tabid.") or (crmentity.smownerid in (0) and (";
+
+ if(sizeof($current_user_groups) > 0)
+ {
+ $sec_query .= "groups.groupid in".getCurrentUserGroupList()." or ";
+ }
+ $sec_query .= "groups.groupid in(select tmp_read_group_sharing_per.sharedgroupid from tmp_read_group_sharing_per where userid=".$current_user->id." and tabid=".$tabid.")))) ";
+
+
}
else
{
More information about the vtigercrm-commits
mailing list