readjust grantor record layout

This commit is contained in:
skeeter 2001-02-13 01:00:16 +00:00
parent c58afa9745
commit 5de5b936ab
2 changed files with 4 additions and 7 deletions

View File

@ -71,7 +71,7 @@
while(list($right,$permission) = each($acllist)) {
$totalacl += $right;
}
$acl->add($phpgw_info["flags"]["currentapp"],'g_'.$group_id,$totalacl);
$acl->add($phpgw_info["flags"]["currentapp"],$group_id,$totalacl);
}
// User records
@ -83,7 +83,7 @@
while(list($right,$permission) = each($acllist)) {
$totalacl += $right;
}
$acl->add($phpgw_info["flags"]["currentapp"],'u_'.$user_id,$totalacl);
$acl->add($phpgw_info["flags"]["currentapp"],$user_id,$totalacl);
}
}

View File

@ -327,9 +327,6 @@ It should use the values in the $this->data
$db2 = $this->db;
$group_pre = 'g_';
$user_pre = 'u_';
if ($app==False)
{
$app = $phpgw_info['flags']['currentapp'];
@ -337,12 +334,12 @@ It should use the values in the $this->data
$sql = "select acl_account, acl_rights from phpgw_acl where acl_appname = '$app' and "
. "acl_location in ";
$security = "('". $user_pre . $phpgw_info['user']['account_id'] ."'";
$security = "('". $phpgw_info['user']['account_id'] ."'";
$my_memberships = $phpgw->accounts->memberships($phpgw_info['user']['account_id']);
while($groups = each($my_memberships))
{
$group = each($groups);
$security .= ",'" . $group_pre . $group[1]['account_id'] . "'";
$security .= ",'" . $group[1]['account_id'] . "'";
}
$security .= ')';
$db2->query($sql . $security ,__LINE__,__FILE__);