function reload() { $("#dgStaffList").cmsXDataTable("load", $.getDataGridParams("dgStaffList")); } //获取选中的数据 function validChoose() { var d = []; $.each($("#dgStaffList").cmsXDataTable("getSelections"), function (index) { d.push(this); }); return d; } function QueryCampusDropdownList(data) { $("#CollegeDropdown").combobox("reload", CMS_SystemConfig.VirtualDirectoryPath + "/College/CollegeDropdownListBanid?campusID=" + data.Value + ""); reload(); } function QueryCollegeDropdownList(data) { $("#DepartmentDropdown").combobox("reload", CMS_SystemConfig.VirtualDirectoryPath + "/Department/DepartmentDropdownListBanid?collegeID=" + data.Value + ""); reload(); } function QueryDepartmentDropdownList(data) { reload(); } function QueryPhotoUrltmentDropdownList(data) { reload(); } function Teacher_Confirm() { var d = validChoose(); var windowID = $.SystemGeneral.getUrlParam("WindowID"); var maxSelect = $.SystemGeneral.getUrlParam("MaxSelect"); if (!maxSelect || isNaN(maxSelect)) maxSelect = 0; if (d.length == 0) { $.messager.alert("系统提示", "请选择教师。"); return; } if (maxSelect > 0 && d.length > maxSelect) { $.messager.alert("系统提示", "只能选择" + maxSelect + "项记录。"); return; } top.$("#" + windowID).data("resultData", d); top.$("#" + windowID).dialog("close"); }