version 1.161, 2016/04/06 17:41:52
|
version 1.162, 2016/04/15 19:27:37
|
Line 118 sub print_course_creation_page {
|
Line 118 sub print_course_creation_page {
|
my $endtime = time+(6*30*24*60*60); # 6 months from now, approx |
my $endtime = time+(6*30*24*60*60); # 6 months from now, approx |
my $access_table = &Apache::lonuserutils::date_setting_table($starttime, |
my $access_table = &Apache::lonuserutils::date_setting_table($starttime, |
$endtime,'create_defaultdates'); |
$endtime,'create_defaultdates'); |
if ($crstype eq 'Course') { |
if (($crstype eq 'Course') || ($crstype eq 'Placement')) { |
$enroll_table = &Apache::lonuserutils::date_setting_table($starttime, |
$enroll_table = &Apache::lonuserutils::date_setting_table($starttime, |
$endtime,'create_enrolldates'); |
$endtime,'create_enrolldates'); |
($krbdef,$krbdefdom) = |
($krbdef,$krbdefdom) = |
Line 132 sub print_course_creation_page {
|
Line 132 sub print_course_creation_page {
|
$krbform = &Apache::loncommon::authform_kerberos(%param); |
$krbform = &Apache::loncommon::authform_kerberos(%param); |
$intform = &Apache::loncommon::authform_internal(%param); |
$intform = &Apache::loncommon::authform_internal(%param); |
$locform = &Apache::loncommon::authform_local(%param); |
$locform = &Apache::loncommon::authform_local(%param); |
} elsif ($crstype eq 'Community') { |
} else { |
my $title_alert = &mt('A Community title is required'); |
my $title_alert = &mt('A Community title is required'); |
my $coord_alert = &mt('The username of the Coordinator is required'); |
my $coord_alert = &mt('The username of the Coordinator is required'); |
&js_escape(\$title_alert); |
&js_escape(\$title_alert); |
Line 149 function validate(formname) {
|
Line 149 function validate(formname) {
|
formname.submit(); |
formname.submit(); |
} |
} |
|; |
|; |
} else { |
|
my $title_alert = &mt('A Placement Test title is required'); |
|
my $coord_alert = &mt('The username of the Course Coordinator is required'); |
|
&js_escape(\$title_alert); |
|
&js_escape(\$coord_alert); |
|
$javascript_validations = qq| |
|
function validate(formname) { |
|
if (formname.title == '') { |
|
alert("$title_alert"); |
|
return; |
|
} |
|
if (formname.ccuname == '') { |
|
alert("$coord_alert"); |
|
} |
|
formname.submit(); |
|
} |
|
|; |
|
|
|
} |
} |
my %lt=&Apache::lonlocal::texthash( |
my %lt=&Apache::lonlocal::texthash( |
'cinf' => "Course Information", |
'cinf' => "Course Information", |
Line 612 END
|
Line 594 END
|
<p> |
<p> |
<input type="hidden" name="prevphase" value="placementone" /> |
<input type="hidden" name="prevphase" value="placementone" /> |
<input type="hidden" name="phase" value="placementtwo" /> |
<input type="hidden" name="phase" value="placementtwo" /> |
<input type="submit" value="'.$lt{'oppt'}.'" /> |
<input type="button" onclick="verify_message(this.form)" value="'.$lt{'oppt'}.'" /> |
</p>' |
</p>' |
); |
); |
} |
} |