%#-- Begin HTML --# <& '/widgets/wrappers/sharky/header.mc', title => "$grp_name Permissions", context => "Admin | Profile | $disp | "$grp_name" | Permissions" &>
<%perl>; $m->comp('/widgets/profile/hidden.mc', value => $id, name => 'grp_id' ) if defined $id; $m->comp('/widgets/perm/perm.mc', grp => $grp, perm_type => $ARGS{'perm_type'}, read_only => $no_edit); # Add the buttons. $m->comp('/widgets/profile/imageSubmit.mc', formName => "perm_profile", callback => "$widget|save_cb", image => 'save_red', alt => 'Save', ); $m->out(' '); $m->comp('/widgets/profile/imageSubmit.mc', formName => "perm_profile", callback => "$widget|save_and_stay_cb", image => 'save_and_stay_lgreen', ); $m->out(' '); $m->comp('/widgets/profile/imageSubmit.mc', formName => "perm_profile", callback => "$widget|cancel_cb", image => 'cancel_red', );
<& '/widgets/wrappers/sharky/footer.mc', param => \%ARGS &> %#-- End HTML --# %#-- Once Section --# <%once>; my $type = 'grp'; my $class = get_package_name($type); my $section = 'admin'; my $widget = 'perm'; %#-- Args Section --# <%args> $id => undef %#-- Init Section --# <%init>; # Instantiate an object. my $grp = $ARGS{obj} ? $ARGS{obj} : defined $id ? $class->lookup({ id => $id}) : $class->new; $id ||= $grp->get_id; # Check authorization. chk_authz($grp, READ); my $no_edit = !chk_authz($grp, ($id ? EDIT : CREATE), 1); my $class_obj = $grp->my_class; my $disp = $class_obj->get_disp_name; my $grp_name = $grp->get_name; <%doc> ############################################################################### =head1 NAME /admin/profile/grp/perm - Group profile permissions interface =head1 VERSION $LastChangedRevision$ =head1 DATE $LastChangedDate$ =head1 DESCRIPTION Diplays the permissions for a single group.