--- loncom/interface/loncreateuser.pm 2013/07/19 18:24:17 1.381 +++ loncom/interface/loncreateuser.pm 2013/12/09 21:33:32 1.382 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # Create a user # -# $Id: loncreateuser.pm,v 1.381 2013/07/19 18:24:17 bisitz Exp $ +# $Id: loncreateuser.pm,v 1.382 2013/12/09 21:33:32 raeburn Exp $ # # Copyright Michigan State University Board of Trustees # @@ -4804,6 +4804,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; @@ -4823,6 +4824,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'; @@ -4841,6 +4852,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;