新建课程报404

This commit is contained in:
cxt 2016-05-11 11:47:16 +08:00
parent 320c3881ef
commit d232a5241e
2 changed files with 3 additions and 3 deletions

View File

@ -9,7 +9,7 @@
<input type="password" style="display: none"/> <!--阻止表单自动填充 -->
<label><span class="c_red">*</span>&nbsp;<%= l(:label_tags_course_name)%>&nbsp;&nbsp;</label>
<input type="text" name="course[name]" id="course_name" class="courses_input" maxlength="100" onkeyup="regex_course_name();">
<span class="c_red" id="course_name_notice" style="display: none;">课程名称不能为空</span>
<span class="c_red" id="course_name_notice" style="display: none;">课程名称不能为空且至少有两个字符</span>
</li>
<div class="cl"></div>
<li class="ml45">

View File

@ -76,7 +76,7 @@ function hidden_homework_score_form()
function regex_course_name()
{
var name = $.trim($("#course_name").val());
if(name.length == 0)
if(name.length < 2)
{
$("#course_name_notice").show();
return false;