|
@@ -35,11 +35,10 @@
|
|
|
<div class="layui-inline">
|
|
|
<label class="layui-form-label"><font color='red' size="4">*</font>类型:</label>
|
|
|
<div class="layui-input-inline">
|
|
|
- <select name="type" lay-verify="required">
|
|
|
+ <select id="id_type" name="type" lay-verify="required">
|
|
|
<option value="">请选择类型</option>
|
|
|
<option value="1">模拟试卷</option>
|
|
|
<option value="2">正式试卷</option>
|
|
|
- <option value="3">随机试卷</option>
|
|
|
</select>
|
|
|
</div>
|
|
|
</div>
|
|
@@ -205,18 +204,19 @@
|
|
|
var subject_value = subject[i].name;
|
|
|
subject_node.append("<option value='" + pid + "'>" + subject_value + "</option>");
|
|
|
}
|
|
|
+ loadData();
|
|
|
form.render();
|
|
|
- loadData()
|
|
|
}
|
|
|
});
|
|
|
var loadData = function () {
|
|
|
if (id) {
|
|
|
var editdata = JSON.parse(JSON.stringify(parent.layui.table.editdata)); // 框架有Bug所以这么转换
|
|
|
form.val("component-form-element", editdata);
|
|
|
- $('#id_fill_total_count').html('共 ' + editdata.fill_total_count + ' 题')
|
|
|
- $('#id_judgment_total_count').html('共 ' + editdata.judgment_total_count + ' 题')
|
|
|
- $('#id_multiple_total_count').html('共 ' + editdata.multiple_total_count + ' 题')
|
|
|
- $('#id_single_total_count').html('共 ' + editdata.single_total_count + ' 题')
|
|
|
+ $('#id_fill_total_count').html('共 ' + editdata.fill_total_count + ' 题');
|
|
|
+ $('#id_judgment_total_count').html('共 ' + editdata.judgment_total_count + ' 题');
|
|
|
+ $('#id_multiple_total_count').html('共 ' + editdata.multiple_total_count + ' 题');
|
|
|
+ $('#id_single_total_count').html('共 ' + editdata.single_total_count + ' 题');
|
|
|
+ $('#id_type').attr('disabled', 'disabled');
|
|
|
}
|
|
|
};
|
|
|
|