CollegeTeacherMonthReport.js 3.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697
  1. function queryTeacher(data) {
  2. if (((data.length && data.length > 0) || data)
  3. && $("#cgbTeacher").length > 0 && $.data($("#cgbTeacher")[0], "combogridX")) {
  4. var jsonString = "({'QueryParamsDatas':'";
  5. var collegeID = $("#ddlCollege").combobox("getValue");
  6. if (collegeID != nonSelect) {
  7. jsonString += "CollegeDropdown|*|" + collegeID + "|@|";
  8. }
  9. jsonString += "'})";
  10. $("#cgbTeacher").combogridX("reload", eval(jsonString));
  11. }
  12. }
  13. function queryStandard() {
  14. try {
  15. var jsonString = "({'QueryParamsDatas':'";
  16. var yearID = $("#ddlYear").combobox("getValue");
  17. if (yearID != nonSelect) {
  18. jsonString += "DictionaryGrade|*|" + yearID + "|@|";
  19. }
  20. jsonString += "'})";
  21. $("#cgbStandard").combogridX("reload", eval(jsonString));
  22. queryClass();
  23. } catch (e) {
  24. }
  25. }
  26. function queryClass() {
  27. try {
  28. var jsonString = "({'QueryParamsDatas':'";
  29. var yearID = $("#ddlYear").combobox("getValue");
  30. var standardID = $("#cgbStandard").combogridX("getValue");
  31. if (yearID != nonSelect) {
  32. jsonString += "DictionaryGrade|*|" + yearID + "|@|";
  33. }
  34. if (standardID != nonSelect) {
  35. jsonString += "DictionaryStandard|*|" + standardID + "|@|";
  36. }
  37. jsonString += "'})";
  38. $("#cgbClassmajor").combogridX("reload", eval(jsonString));
  39. } catch (e) {
  40. }
  41. }
  42. function reload() {
  43. var schoolYearID = $("#ddlSchoolyear").combobox("getValue");
  44. var collegeID = $("#ddlCollege").combobox("getValue");
  45. var userID = $("#cgbTeacher").combogridX("getValue");
  46. var yearID = $("#ddlYear").combobox("getValue");
  47. var standardID = $("#cgbStandard").combogridX("getValue");
  48. var classmajorID = $("#cgbClassmajor").combogridX("getValue");
  49. var coursematerialID = $("#cgbCourse").combogridX("getValue");
  50. var Month = document.getElementById("txtDate").value;
  51. var MonthStr ="";
  52. if (Month != null && Month != "") {
  53. if (isNaN(Month)) {
  54. $.messager.alert("系统提示", "请输入正确的月份");
  55. } else {
  56. if (Month < 1 || Month > 12) {
  57. $.messager.alert("系统提示", "请输入正确的月份");
  58. return;
  59. }
  60. if (Month < 10) {
  61. MonthStr = "0" + Month;
  62. } else {
  63. MonthStr = Month;
  64. }
  65. }
  66. } else {
  67. MonthStr = null;
  68. }
  69. if (collegeID == nonSelect) collegeID = null;
  70. if (userID == nonSelect) userID = null;
  71. if (yearID == nonSelect) yearID = null;
  72. if (standardID == nonSelect) standardID = null;
  73. if (classmajorID == nonSelect) classmajorID = null;
  74. if (coursematerialID == nonSelect) coursematerialID = null;
  75. top.ReportParameter = {
  76. SchoolyearID: schoolYearID,
  77. CollegeID: collegeID,
  78. TeacherUserID: userID,
  79. GradeyearID: yearID,
  80. StandardID: standardID,
  81. ClassmajorID: classmajorID,
  82. CoursematerialID: coursematerialID,
  83. Month: MonthStr
  84. };
  85. if (schoolYearID == nonSelect || !schoolYearID)
  86. $.messager.alert("系统信息", "请选择学年学期。");
  87. else
  88. $("#reportContent").attr("src", CMS_SystemConfig.VirtualDirectoryPath + CMS_SystemConfig.ScriptReportPagePath + "?ReportFolder=%2fPaymentManage%2fCollegeTeacherMonthReport");
  89. }