var refreshGirdData; var StuId; var tempdatra = new Array(); var list = []; var bootstrap = function ($, learun) { "use strict"; var page = { init: function () { page.bind(); }, bind: function () { //选项卡切换 $('#navultab li').on('click', function () { if (!$(this).hasClass('active')) { $(this).parent().find('.active').removeClass('active'); $(this).addClass('active'); $('#condivtab .condiv').eq($(this).index()).siblings().hide() $('#condivtab .condiv').eq($(this).index()).show() } }); //转出 $("#EducationExperienceReturn").attr("src", "/EducationalAdministration/StuTransferInfo/RolloffIndex"); //提交下拉框 $('#NewDeptNo').lrselect({ allowSearch: true, value: "deptno", text: "deptname", url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=CdDeptInfo', select: function (item) { if (item) { $('#NewMajorNo').lrselectRefresh({ allowSearch: true, url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=CdMajorInfo', param: { strWhere: "DeptNo='" + item.deptno + "' AND CheckMark=1" } }); } else { $('#NewMajorNo').lrselectRefresh({ allowSearch: true, url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=CdMajorInfo', param: { strWhere: "1=1 AND CheckMark=1" } }); } } }); $('#NewMajorNo').lrselect({ allowSearch: true, url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=CdMajorInfo', value: "majorno", text: "majorname", param: { strWhere: "1=1 AND CheckMark=1" }, select: function (item) { var Grades = $("#NewGrade").lrselectGet(); if (Grades != null && Grades != "" && Grades != "undefined") { if (item) { $('#NewClassNo').lrselectRefresh({ allowSearch: true, url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=bjsj', param: { strWhere: "majorno='" + item.majorno + "' AND CheckMark=1 AND Grade='" + Grades + "' order by classno desc" } }); } else { $('#NewClassNo').lrselectRefresh({ allowSearch: true, url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=bjsj', param: { strWhere: "1=1 AND CheckMark=1 order by classno desc" } }); } } else { if (item) { $('#NewClassNo').lrselectRefresh({ allowSearch: true, url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=bjsj', param: { strWhere: "majorno='" + item.majorno + "' AND CheckMark=1 order by classno desc" } }); } else { $('#NewClassNo').lrselectRefresh({ allowSearch: true, url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=bjsj', param: { strWhere: "1=1 AND CheckMark=1 order by classno desc" } }); } } } }); $('#NewGrade').lrselect({ url: top.$.rootUrl + '/EducationalAdministration/ClassInfo/GenerateNearByYear', value: "value", text: "text", select: function (item) { var MajorNos = $("#NewMajorNo").lrselectGet(); if (MajorNos != null && MajorNos != "" && MajorNos != "undefined") { if (item) { $('#NewClassNo').lrselectRefresh({ allowSearch: true, url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=bjsj', param: { strWhere: "majorno='" + MajorNos + "' AND CheckMark=1 AND Grade='" + item.text + "' order by classno desc" } }); } else { $('#NewClassNo').lrselectRefresh({ allowSearch: true, url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=bjsj', param: { strWhere: "1=1 AND CheckMark=1 order by classno desc" } }); } } else { if (item) { $('#NewClassNo').lrselectRefresh({ allowSearch: true, url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=bjsj', param: { strWhere: "CheckMark=1 AND Grade='" + item.text + "' order by classno desc" } }); } else { $('#NewClassNo').lrselectRefresh({ allowSearch: true, url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=bjsj', param: { strWhere: "1=1 AND CheckMark=1 order by classno desc" } }); } } } }); $('#NewClassNo').lrselect({ allowSearch: true, url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=bjsj', param: { strWhere: "1=1 AND CheckMark=1 order by classno desc" }, value: "classno", text: "classname" }); $('#IdCardType').lrDataItemSelect({ code: 'IdCardType' }); $('#Gender').lrDataItemSelect({ code: 'usersexbit' }); $('#NationalityNo').lrDataItemSelect({ code: 'National' }); $('#IsInAccommodation').lrDataItemSelect({ code: 'YesOrNoInt' }); // 提交 $('#subbtn').on('click', function () { if (!$('body').lrValidform()) { return false; } var entity = $('body').lrGetFormData(); $.lrSaveForm(top.$.rootUrl + '/EducationalAdministration/StuTransferInfo/SaveFormOfIn', { keyValue: '', strEntity: JSON.stringify(entity) }, function (res) { if (res.code == 200) { setTimeout(function () { location.reload(); }, 100) } } ); }) }, }; refreshGirdData = function () { page.search(); }; page.init(); }