[#6333] Permissions with from/to - backend hook
Summary Permissions with from/to - backend hook
Queue Kronolith
Queue Version HEAD
Type Bug
State Duplicate
Priority 1. Low
Owners
Requester grahamcw (at) hurleybulldogs (dot) com
Created 02/27/2008 (74 days ago)
Due
Updated 03/23/2008 (49 days ago)
Assigned 02/28/2008 (73 days ago)
Resolved 03/23/2008 (49 days ago)
Attachments
Milestone
Patch

History
03/23/2008 Jan Schneider Comment #3
State ⇒ Duplicate
Taken from Jan Schneider
Reply to this comment
Bug #6371 is a duplicate of this one, but has a potential patch.
02/28/2008 Chuck Hagenbuch Comment #2
State ⇒ Assigned
Assigned to Jan Schneider
Reply to this comment
Jan, I believe you did the relevant work here.
02/27/2008 Chuck Hagenbuch Summary ⇒ Permissions with from/to - backend hook
 
02/27/2008 grahamcw (at) hurleybulldogs (dot) com Comment #1
Queue ⇒ Kronolith
Summary ⇒ Permissions with fromt/to - backend hook
Type ⇒ Bug
Priority ⇒ 1. Low
State ⇒ Unconfirmed
Reply to this comment

From Calendar
Select Manage calendars from right expando-manu
Select change permissions icon on right of an existing calender

In Permission window
Enter Bob in individual users input area and select all options except delegate
Push Save Calender Submit  button
No w enter John in individual users input area and select all options except delegate
Push Save Calendar Submit botton
it will return Individual user list
Bob
bob@hurleybulldogs.com
John

Enter Jim in individuall users input area and select all options except delegate
Push Save Calendar Submit botton

it will return individual user list
Bob
Bob@hurleybulldogs.com@hurleybulldogs.com
John
John@hurleybulldogs.com
Jim

Now de-select all permission options under individual Users - deleting them
Push Save Calendar Submit botton
it will return the list
Bob
John
Jim



--------------------------
Here are the hooks

if (!function_exists('_username_hook_tobackend')) {
     function _username_hook_tobackend($userID)
     {
         $vdomain = '@hurleybulldogs.com';
         if (substr($userID, -strlen($vdomain)) == $vdomain) {
             $userID = substr($userID, 0, -strlen($vdomain));
         }

         return String::lower($userID);
     }
}

if (!function_exists('_username_hook_frombackend')) {
     function _username_hook_frombackend($userID)
     {

           $vdomain = 'hurleybulldogs.com';

         return String::lower($userID) . '@' . $vdomain;
     }
}