PersonalList.js 3.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960
  1. function Report_Search() {
  2. var schoolYearID = $("#SchoolYearDropdown").combobox("getValue");
  3. var collegeID = $("#DDCollegeDropdown").combogridX("getValue");
  4. collegeID = collegeID == -1 ? "=" : "=" + collegeID;
  5. var Month = document.getElementById("txtDate").value;
  6. var EndMonth = document.getElementById("txtEndDate").value;
  7. if (Month != null && Month != "") {
  8. if (isNaN(Month)) {
  9. $.messager.alert("系统提示", "请输入正确的月份");
  10. } else {
  11. if (EndMonth != null && EndMonth != "") {
  12. if (isNaN(EndMonth)) {
  13. $.messager.alert("系统提示", "请输入正确的月份");
  14. } else {
  15. var monthNum = Number(Month);
  16. var endMonthNum = Number(EndMonth);
  17. var MonthStr = Month.toString();
  18. var EndMonthStr = EndMonth.toString();
  19. if (Month < 1 || Month > 12||EndMonth<1||EndMonth>12) {
  20. $.messager.alert("系统提示", "请输入正确的月份");
  21. return;
  22. }
  23. if (monthNum > endMonthNum) {
  24. $.messager.alert("系统提示", "开始月份不能大于结束月份");
  25. return;
  26. }
  27. if (Month < 10) {
  28. MonthStr = "0" + Month;
  29. if(EndMonth<10){
  30. EndMonthStr = "0" + EndMonth;
  31. }
  32. $("#reportContent").attr("src", CMS_SystemConfig.ReportPagePath + "?ReportFolder=%2fSUPManage%2fSuppersonalCount&SchoolyearID_RAP=" + schoolYearID + "&CollegeID_RAP" + collegeID + "&Month_RAP=" + MonthStr + "&EndMonth_RAP=" + EndMonthStr);
  33. } else {
  34. $("#reportContent").attr("src", CMS_SystemConfig.ReportPagePath + "?ReportFolder=%2fSUPManage%2fSuppersonalCount&SchoolyearID_RAP=" + schoolYearID + "&CollegeID_RAP" + collegeID + "&Month_RAP=" + MonthStr + "&EndMonth_RAP=" + EndMonthStr);
  35. }
  36. }
  37. } else {
  38. var MonthStr = Month.toString();
  39. var EndMonthStr = "";
  40. EndMonth = null;
  41. if (Month < 1 || Month > 12) {
  42. $.messager.alert("系统提示", "请输入正确的月份");
  43. return;
  44. }
  45. if (Month < 10) {
  46. MonthStr = "0" + Month;
  47. $("#reportContent").attr("src", CMS_SystemConfig.ReportPagePath + "?ReportFolder=%2fSUPManage%2fSuppersonalCount&SchoolyearID_RAP=" + schoolYearID + "&CollegeID_RAP" + collegeID + "&Month_RAP=" + MonthStr + "&EndMonth_RAP=" + EndMonthStr);
  48. } else {
  49. $("#reportContent").attr("src", CMS_SystemConfig.ReportPagePath + "?ReportFolder=%2fSUPManage%2fSuppersonalCount&SchoolyearID_RAP=" + schoolYearID + "&CollegeID_RAP" + collegeID + "&Month_RAP=" + MonthStr + "&EndMonth_RAP=" + EndMonthStr);
  50. }
  51. }
  52. }
  53. } else {
  54. var EndMonthStr = "";
  55. EndMonth = null;
  56. $("#reportContent").attr("src", CMS_SystemConfig.ReportPagePath + "?ReportFolder=%2fSUPManage%2fSuppersonalCount&SchoolyearID_RAP=" + schoolYearID + "&CollegeID_RAP" + collegeID + "&Month_RAP=" + Month + "&EndMonth_RAP=" + EndMonthStr);
  57. }
  58. }