处理课程绑定

beetlsql3-dev
yangdj 2 years ago
parent 8c8d269d92
commit 677c4cdf64

@ -96,13 +96,17 @@ layui.define(['form', 'laydate', 'table', 'dropdown', 'util'], function (exports
align: "center", align: "center",
templet: function (d) { templet: function (d) {
var htm = ''; var htm = '';
// htm += '<a class="layui-table-link" lay-event="binding">绑定</a>'; if(d.sourceType == 1){
if (d.courseLabelType == "应用课程类" && $.isEmpty(d.resourcesApplicationIds)) { htm = '<a class="layui-table-link" lay-event="see">查看</a>';
htm += '<input type="checkbox" name="" lay-filter="binding" title="绑定">'; }else {
} else { // htm += '<a class="layui-table-link" lay-event="binding">绑定</a>';
htm += '<input type="checkbox" name="" lay-filter="binding" checked title="绑定">'; if (d.courseLabelType == "应用课程类" && $.isEmpty(d.resourcesApplicationIds)) {
htm += '<input type="checkbox" name="" lay-filter="binding" title="绑定">';
} else {
htm += '<input type="checkbox" name="" lay-filter="binding" checked title="绑定">';
}
htm += '<a class="layui-table-link" style="padding-left: 15px" lay-event="edit">编辑</a>';
} }
htm += '<a class="layui-table-link" style="padding-left: 15px" lay-event="edit">编辑</a>';
return htm; return htm;
} }
} }
@ -233,6 +237,9 @@ layui.define(['form', 'laydate', 'table', 'dropdown', 'util'], function (exports
}); });
updateBindingBtnStatus(this); updateBindingBtnStatus(this);
form.render(); form.render();
}else if (obj.event === "see") {
var url = "/jlw/teacherOpenCourseMergeCourseInfo/courseConfigureNew.do?teacherOpenCourseld="+data.courseInfoId;
Common.openDlg(url,"");
} }
}) })
}; };

@ -35,13 +35,18 @@
<!--课程类别--> <!--课程类别-->
<script type="text/html" id="select_courseLabelTypeSelect"> <script type="text/html" id="select_courseLabelTypeSelect">
<select lay-filter="select_courseLabelType" name="courseLabelType"> {{#if(d.sourceType == 1){}}
<option value="">请选择</option> -
{{# layui.each(window.disLabelTypeSelectList, function(index, item){ }} {{#}else{}}
<option value="{{item}}" {{ item== d.courseLabelType ? <select lay-filter="select_courseLabelType" name="courseLabelType">
'selected' : '' }}>{{item}}</option> <option value="">请选择{{d.courseLabelType}}</option>
{{# }); }} {{# layui.each(window.disLabelTypeSelectList, function(index, item){ }}
</select> <option value="{{item}}" {{ item== d.courseLabelType ?
'selected' : '' }}>{{item}}</option>
{{# }); }}
</select>
{{#}}}
</script> </script>
<!--绑定模块--> <!--绑定模块-->
@ -54,19 +59,23 @@
</select> </select>
</script>--> </script>-->
<script type="text/html" id="select_courseLabelIdSelect"> <script type="text/html" id="select_courseLabelIdSelect">
{{# if(d.courseLabelType == '理论课程类'){ }} {{#if(d.sourceType == 1){}}
<input lay-event="labelSelect" name="courseLabelId" placeholder="请选择" class="layui-input" -
value="课程中心 / {{d.courseLabelName}}"/> {{#}else{}}
{{# }else{ }} {{# if(d.courseLabelType == '理论课程类'){ }}
<select lay-filter="select_courseLabelId" name="courseLabelId"> <input lay-event="labelSelect" name="courseLabelId" placeholder="请选择" class="layui-input"
<option value="">请选择</option> value="课程中心 / {{d.courseLabelName}}"/>
{{# if(d.courseLabelType == '应用课程类'){ }} {{# }else{ }}
<option value="应用中心" selected>应用中心</option> <select lay-filter="select_courseLabelId" name="courseLabelId">
{{# }else if(d.courseLabelType == '考证课程类'){ }} <option value="">请选择</option>
<option value="考证辅导" selected>考证辅导</option> {{# if(d.courseLabelType == '应用课程类'){ }}
{{# } }} <option value="应用中心" selected>应用中心</option>
</select> {{# }else if(d.courseLabelType == '考证课程类'){ }}
{{# } }} <option value="考证辅导" selected>考证辅导</option>
{{# } }}
</select>
{{# } }}
{{#}}}
</script> </script>
<!--绑定应用--> <!--绑定应用-->

Loading…
Cancel
Save