--- loncom/interface/loncreateuser.pm 2013/07/03 04:04:13 1.379
+++ loncom/interface/loncreateuser.pm 2013/12/17 06:41:44 1.383
@@ -1,7 +1,7 @@
# The LearningOnline Network with CAPA
# Create a user
#
-# $Id: loncreateuser.pm,v 1.379 2013/07/03 04:04:13 raeburn Exp $
+# $Id: loncreateuser.pm,v 1.383 2013/12/17 06:41:44 raeburn Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -189,19 +189,19 @@ END_SCRIPT
$showquota = $currquota;
if ($longinsttype eq '') {
$defaultinfo = &mt('For this user, the default quota would be [_1]'
- .' Mb.',$defquota);
+ .' MB.',$defquota);
} else {
$defaultinfo = &mt("For this user, the default quota would be [_1]".
- " Mb, as determined by the user's institutional".
+ " MB, as determined by the user's institutional".
" affiliation ([_2]).",$defquota,$longinsttype);
}
} else {
if ($longinsttype eq '') {
$defaultinfo = &mt('For this user, the default quota is [_1]'
- .' Mb.',$defquota);
+ .' MB.',$defquota);
} else {
$defaultinfo = &mt("For this user, the default quota of [_1]".
- " Mb, is determined by the user's institutional".
+ " MB, is determined by the user's institutional".
" affiliation ([_2]).",$defquota,$longinsttype);
}
}
@@ -212,7 +212,7 @@ END_SCRIPT
' '."\n".
&Apache::loncommon::start_data_table_row()."\n".
'
'.$lt{'cuqu'}.': '.
- $currquota.' Mb. '.
+ $currquota.' MB. '.
$defaultinfo.' | '."\n".
&Apache::loncommon::end_data_table_row()."\n".
&Apache::loncommon::start_data_table_row()."\n".
@@ -220,13 +220,13 @@ END_SCRIPT
': '.
+ ' />'.$lt{'defa'}.' ('.$defquota.' MB). '.
' '.
' Mb'."\n".
+ ' /> MB'."\n".
&Apache::loncommon::end_data_table_row()."\n";
}
}
@@ -568,6 +568,15 @@ sub requestauthor_display {
return %titles;
}
+sub requestchange_display {
+ my %titles = &Apache::lonlocal::texthash (
+ approval => "availability set to 'on' (approval required)",
+ automatic => "availability set to 'on' (automatic approval)",
+ norequest => "availability set to 'off'",
+ );
+ return %titles;
+}
+
sub curr_requestauthor {
my ($uname,$udom,$isadv,$inststatuses,$domconfig) = @_;
return unless ((ref($inststatuses) eq 'ARRAY') && (ref($domconfig) eq 'HASH'));
@@ -988,7 +997,7 @@ ENDSCRIPT
$r->print('');
}
}
- $r->print('';
return $outcome;
}
@@ -4124,7 +4246,7 @@ sub custom_role_editor {
$r->print('
');
$r->print(<
+');
+ $r->print(
+ ''
+ .&mt('Create or edit another custom role')
+ .'
'
+ .''
+ );
}
# ================================================================ Main Handler
@@ -4799,6 +4926,7 @@ function updateCols(caller) {
document.getElementById('showcolrole').disabled = 'disabled';
}
if (context == 'domain') {
+ var quotausageshow = 0;
if ((document.studentform.roletype.options[document.studentform.roletype.selectedIndex].value == 'course') ||
(document.studentform.roletype.options[document.studentform.roletype.selectedIndex].value == 'community')) {
document.getElementById('showcolstatus').checked = false;
@@ -4818,6 +4946,16 @@ function updateCols(caller) {
document.getElementById('showcolextent').checked = 'false';
document.getElementById('showextent').style.display='none';
document.getElementById('showcoltextextent').innerHTML = '';
+ if ((document.studentform.showrole.options[document.studentform.showrole.selectedIndex].value == 'au') ||
+ (document.studentform.showrole.options[document.studentform.showrole.selectedIndex].value == 'Any')) {
+ if (document.getElementById('showcolauthorusage')) {
+ document.getElementById('showcolauthorusage').disabled = '';
+ }
+ if (document.getElementById('showcolauthorquota')) {
+ document.getElementById('showcolauthorquota').disabled = '';
+ }
+ quotausageshow = 1;
+ }
} else {
document.getElementById('showextent').style.display='block';
document.getElementById('showextent').style.textAlign='left';
@@ -4836,6 +4974,16 @@ function updateCols(caller) {
}
}
}
+ if (quotausageshow == 0) {
+ if (document.getElementById('showcolauthorusage')) {
+ document.getElementById('showcolauthorusage').checked = false;
+ document.getElementById('showcolauthorusage').disabled = 'disabled';
+ }
+ if (document.getElementById('showcolauthorquota')) {
+ document.getElementById('showcolauthorquota').checked = false;
+ document.getElementById('showcolauthorquota').disabled = 'disabled';
+ }
+ }
}
}
return;