%# No one can make you feel inferior without your consent. %# -- Eleanor Roosevelt <& /Edit/Elements/PickUserPopup, %ARGS, Check => sub { $_[0]->PrincipalObj->HasRight( Right => 'OwnTicket', Object => $QueueObj) } &> <%INIT> my $QueueObj = RT::Queue->new($session{'CurrentUser'}); $QueueObj->Load($Queue) or Abort("Cannot load queue $Queue"); if ($ARGS{'Action-Commit'} and $User) { # Can't set a queue without an AdminCc here foreach my $User (@{$QueueObj->AdminCc->UserMembersObj->ItemsArrayRef}) { $QueueObj->AdminCc->DeleteMember($User->PrincipalId); } my ($val, $msg) = $QueueObj->AdminCc->AddMember($User); Abort($msg) unless $val; $QueueObj->UpdateCompany if $QueueObj->can('UpdateCompany'); $m->print("
"); $m->abort; } <%ARGS> $User => 0 $IsWork => 0 $Queue => '' $Group => 0 $Job => 0 $CurrentUser => $session{'CurrentUser'}->UserObj->PrincipalId