beetlsql3-dev
姚丹ab 2 years ago
parent 0052e833dd
commit 88eade1289

@ -183,7 +183,7 @@ layui.define(['form', 'laydate', 'table'], function (exports) {
} }
//绑定课程名称选择 //绑定课程名称选择
form.on('select(select_courseLabelType)', function (obj) { /*form.on('select(select_courseLabelType)', function (obj) {
if(!$.isEmpty(obj.value)){ if(!$.isEmpty(obj.value)){
var ret = Common.getAjax("/jlw/courseLabel/getValues.json",{courseLabelType:obj.value,courseLabelStatus:1}); var ret = Common.getAjax("/jlw/courseLabel/getValues.json",{courseLabelType:obj.value,courseLabelStatus:1});
if(ret.code == 0){ if(ret.code == 0){
@ -200,8 +200,34 @@ layui.define(['form', 'laydate', 'table'], function (exports) {
$(this).parents("td").siblings('td').eq(1).find('select').empty(); $(this).parents("td").siblings('td').eq(1).find('select').empty();
form.render(); form.render();
} }
});*/
form.on('select(select_courseLabelType)', function (obj) {
if(!$.isEmpty(obj.value)){
var htm = '<option value="">请选择</option>';
if(obj.value == '应用课程类'){
htm+='<option value="应用中心">应用中心</option>';
}else if(obj.value == "考证课程类"){
htm+='<option value="考砸辅导">考砸辅导</option>';
}else if(obj.value == "理论课程类"){
htm+='<option value="课程中心">课程中心</option>';
}
$(this).parents("td").siblings('td').eq(1).find('select').empty();
$(this).parents("td").siblings('td').eq(1).find('select').append(htm);
updateBindingBtnStatus(this);
form.render();
}else {
var htm =' <option value="">请选择</option>\n' +
' <option value="考证辅导">考证辅导</option>\n' +
' <option value="课程中心">课程中心</option>\n' +
' <option value="应用中心">应用中心</option>'
$(this).parents("td").siblings('td').eq(1).find('select').empty();
$(this).parents("td").siblings('td').eq(1).find('select').append(htm);
form.render();
}
}); });
// 下拉框change事件 // 下拉框change事件
form.on('select(select_courseLabelId)', function (obj) { form.on('select(select_courseLabelId)', function (obj) {
table.cache['resourcesApplicationCourseTable'][$(this).parents("tr").data("index")].courseLabelId = obj.value; table.cache['resourcesApplicationCourseTable'][$(this).parents("tr").data("index")].courseLabelId = obj.value;

@ -45,7 +45,7 @@ layui.define([ 'form', 'laydate', 'table' ], function(exports) {
}, },
{ {
field : 'classSn', field : 'classSn',
title : '班级编号',align: "center",hide:isSignRole == 2?true:false title : '班级编号',align: "center",/*hide:isSignRole == 2?true:false*/
}, },
{ {

@ -24,13 +24,8 @@
</div> </div>
</div> </div>
</layui:searchForm> </layui:searchForm>
<script type="text/html" id="select_resourcesApplicationIds" >
<layui:simpleDictSelect style='layui-input-inline'
layFilter="select_resourcesApplicationIds"
type="resources_application.application_name.1=1"
id="resourcesApplicationIds" name="resourcesApplicationIds"/>
</script>
<!--课程类别-->
<script type="text/html" id="select_courseLabelTypeSelect"> <script type="text/html" id="select_courseLabelTypeSelect">
<select lay-filter="select_courseLabelType" name="courseLabelType"> <select lay-filter="select_courseLabelType" name="courseLabelType">
<option value="">请选择</option> <option value="">请选择</option>
@ -40,13 +35,30 @@
</select> </select>
</script> </script>
<script type="text/html" id="select_courseLabelIdSelect"> <!--绑定模块-->
<!--<script type="text/html" id="select_courseLabelIdSelect">
<select lay-filter="select_courseLabelId" name="courseLabelId"> <select lay-filter="select_courseLabelId" name="courseLabelId">
<option value="">请选择</option> <option value="">请选择</option>
{{# layui.each(window.courseLabelList, function(index, item){ }} {{# layui.each(window.courseLabelList, function(index, item){ }}
<option value="{{item.courseLabelId}}" {{ item.courseLabelId == d.courseLabelId ? 'selected' : '' }}>{{item.courseLabelName}}</option> <option value="{{item.courseLabelId}}" {{ item.courseLabelId == d.courseLabelId ? 'selected' : '' }}>{{item.courseLabelName}}</option>
{{# }); }} {{# }); }}
</select> </select>
</script>-->
<script type="text/html" id="select_courseLabelIdSelect">
<select lay-filter="select_courseLabelId" name="courseLabelId">
<option value="">请选择</option>
<option value="考证辅导">考证辅导</option>
<option value="课程中心">课程中心</option>
<option value="应用中心">应用中心</option>
</select>
</script>
<!--绑定应用-->
<script type="text/html" id="select_resourcesApplicationIds" >
<layui:simpleDictSelect style='layui-input-inline'
layFilter="select_resourcesApplicationIds"
type="resources_application.application_name.1=1"
id="resourcesApplicationIds" name="resourcesApplicationIds"/>
</script> </script>
<table id="resourcesApplicationCourseTable" lay-filter="resourcesApplicationCourseTable"></table> <table id="resourcesApplicationCourseTable" lay-filter="resourcesApplicationCourseTable"></table>

Loading…
Cancel
Save