version 1.97, 2009/05/07 15:25:37
|
version 1.101.4.1, 2010/01/25 22:19:55
|
Line 1440 sub header {
|
Line 1440 sub header {
|
{'add_entries' => $loaditems,}); |
{'add_entries' => $loaditems,}); |
my $output = <<"END"; |
my $output = <<"END"; |
$start_page |
$start_page |
<form method="POST" name="$state"> |
<form method="post" name="$state"> |
|
|
END |
END |
if ($action eq 'create' || $action eq 'modify') { |
if ($action eq 'create' || $action eq 'modify') { |
Line 1888 sub choose_members_form {
|
Line 1888 sub choose_members_form {
|
} |
} |
} |
} |
&privilege_specificity($r,$action,$specimg,$tools,$stored,$toolprivs, |
&privilege_specificity($r,$action,$specimg,$tools,$stored,$toolprivs, |
$fixedprivs,\@available,$formname,$gpterm,$ucgpterm); |
$fixedprivs,\@available,$formname,$gpterm,$ucgpterm, |
|
$functions); |
my $newusers = &pick_new_members($r,$action,$formname,\@available,$idx, |
my $newusers = &pick_new_members($r,$action,$formname,\@available,$idx, |
$stored,$memimg,$users,$userdata, |
$stored,$memimg,$users,$userdata, |
$granularity,\%origmembers,$gpterm, |
$granularity,\%origmembers,$gpterm, |
Line 1985 sub print_current_settings {
|
Line 1986 sub print_current_settings {
|
<td valign="top">'.$description.'</td> |
<td valign="top">'.$description.'</td> |
<td> |
<td> |
'); |
'); |
|
|
if (@{$available} > 0) { |
if (@{$available} > 0) { |
$r->print('<b>'.&mt('Available for assignment to members:').'</b>'. |
$r->print('<b>'.&mt('Available for assignment to members:').'</b>'); |
'<table class="LC_group_priv"><tr>'); |
$r->print('<ul>'); |
my $rowcell = int(@{$available}/2) + @{$available}%2; |
|
for (my $i=0; $i<@{$available}; $i++) { |
for (my $i=0; $i<@{$available}; $i++) { |
if (@{$available} > 3) { |
$r->print('<li>'.&mt($$functions{$$available[$i]}).'</li>'); |
if ($i==$rowcell) { |
|
$r->print('</tr><tr>'); |
|
} |
|
} |
|
$r->print('<td>'.$$functions{$$available[$i]}. |
|
'</td><td> </td>'); |
|
} |
} |
if ((@{$available} > 3) && (@{$available}%2)) { |
$r->print('</ul>'); |
$r->print('<td> </td><td> </td>'); |
|
} |
|
$r->print('</tr></table><br />'); |
|
} |
} |
|
|
if (@{$unavailable} > 0) { |
if (@{$unavailable} > 0) { |
$r->print('<b>'.&mt('Unavailable for assignment:').'</b>'. |
$r->print('<b>'.&mt('Unavailable for assignment:').'</b>'); |
'<table class="LC_group_priv"><tr>'); |
$r->print('<ul>'); |
my $rowcell = int(@{$unavailable}/2) + @{$unavailable}%2; |
for (my $i=0; $i<@{$unavailable}; $i++) { |
for (my $j=0; $j<@{$unavailable}; $j++) { |
$r->print('<li>'.&mt($$functions{$$unavailable[$i]}).'</li>'); |
if (@{$unavailable} > 3) { |
|
if ($j==$rowcell) { |
|
$r->print('</tr><tr>'); |
|
} |
|
} |
|
$r->print('<td>'.$$functions{$$unavailable[$j]}. |
|
'</td><td> </td>'); |
|
} |
|
if ((@{$unavailable} > 3) && (@{$unavailable}%2)) { |
|
$r->print('<td> </td><td> </td>'); |
|
} |
} |
$r->print('</tr></table>'); |
$r->print('</ul>'); |
} |
} |
|
|
my $quota_text=&mt('[_1] Mb',$quota); |
my $quota_text=&mt('[_1] Mb',$quota); |
my $granu_text=&mt($granularity); |
my $granu_text=&mt($granularity); |
$r->print(<<"END"); |
$r->print(<<"END"); |
Line 2314 sub default_privileges {
|
Line 2298 sub default_privileges {
|
&Apache::lonhtmlcommon::row_title($lt{'func'},undef, |
&Apache::lonhtmlcommon::row_title($lt{'func'},undef, |
'LC_groups_functionality')); |
'LC_groups_functionality')); |
my @tableHeader; |
my @tableHeader; |
foreach my $key (sort(keys(%{$functions}))){ |
if ((ref($functions) eq 'HASH') && (ref($tools) eq 'ARRAY')) { |
push (@tableHeader,&mt(${$functions}{$key})); |
@tableHeader = map { $functions->{$_}; } @{$tools}; |
} |
} |
$r->print(join('</td><td class="LC_groups_functionality">', @tableHeader)); |
$r->print(join('</td><td class="LC_groups_functionality">', @tableHeader)); |
$r->print(&Apache::lonhtmlcommon::row_closure(1)); |
$r->print(&Apache::lonhtmlcommon::row_closure(1)); |
my $fixed = ''; |
my $fixed = ''; |
Line 2975 sub member_privileges_form {
|
Line 2959 sub member_privileges_form {
|
foreach my $tool (@{$tools}) { |
foreach my $tool (@{$tools}) { |
if (@{$showboxes{$tool}} > 0) { |
if (@{$showboxes{$tool}} > 0) { |
$r->print('<td valign="top">'); |
$r->print('<td valign="top">'); |
$r->print('<table class="thinborder"><tr>'. |
$r->print('<fieldset><legend>'.&mt($tool).'</legend>'); |
'<th colspan="'.$colspan.'">'. |
$r->print('<table><tr>'); |
&mt($tool).'</th></tr><tr>'); |
|
my $privcount = 0; |
my $privcount = 0; |
foreach my $priv (@{$showboxes{$tool}}) { |
foreach my $priv (@{$showboxes{$tool}}) { |
$privcount ++; |
$privcount ++; |
Line 3012 sub member_privileges_form {
|
Line 2995 sub member_privileges_form {
|
} |
} |
} |
} |
} |
} |
$r->print('</tr></table></td><td> </td>'); |
$r->print('</tr></table></fieldset></td><td> </td>'); |
} |
} |
} |
} |
$r->print('</tr></table>'); |
$r->print('</tr></table>'); |
Line 3776 sub date_setting_table {
|
Line 3759 sub date_setting_table {
|
'startdate',$starttime); |
'startdate',$starttime); |
my $endform = &Apache::lonhtmlcommon::date_setter($formname, |
my $endform = &Apache::lonhtmlcommon::date_setter($formname, |
'enddate',$endtime); |
'enddate',$endtime); |
my $perpetual = |
my $perpetual = ' <span class="LC_nobreak"><label>' |
'<span class="LC_nobreak"><label><input type="checkbox" name="no_end_date" />'. |
.'<input type="checkbox" name="no_end_date" />' |
&mt('None').'</label></span>'; |
.&mt('No end date') |
my $table = "<table class=\"LC_descriptive_input\">\n". |
.'</label></span>'; |
'<tr><td class="LC_description">'.&mt('Start:').'</td>'. |
my $table = &Apache::lonhtmlcommon::start_pick_box() |
'<td>'.$startform.'</td>'. |
.&Apache::lonhtmlcommon::row_title(&mt('Start Date')) |
'<td> </td>'."</tr>\n". |
.$startform |
'<tr><td class="LC_description">'.&mt('End:').'</td>'. |
.&Apache::lonhtmlcommon::row_closure() |
'<td>'.$endform.'</td>'. |
.&Apache::lonhtmlcommon::row_title(&mt('End Date')) |
'<td>'.$perpetual.'</td>'."</tr>\n". |
.$endform |
"</table>\n"; |
.$perpetual |
|
.&Apache::lonhtmlcommon::row_closure(1) |
|
.&Apache::lonhtmlcommon::end_pick_box(); |
return $table; |
return $table; |
} |
} |
|
|