ChargeTotal.js 3.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182
  1. var url = CMS_SystemConfig.VirtualDirectoryPath + "/ChargeTotal/Edit";
  2. var mnu = "";
  3. //加载
  4. $(function () {
  5. mnu = $.SystemGeneral.getUrlParam("MNU");
  6. })
  7. //刷新
  8. function reload() {
  9. $("#dgChargeTotalList").cmsXDataTable("load", $.getDataGridParams("dgChargeTotalList"));
  10. //统计
  11. $.post(CMS_SystemConfig.VirtualDirectoryPath + "/ChargeTotal/ChargeTotalList", $.getDataGridParams("dgChargeTotalList"), function (data) {
  12. //注:其它统计数据已统计(暂时不考虑展示)
  13. //实收总额
  14. $("#actualAmountSum").html(data.ActualAmountSum.toString());
  15. //已收总额
  16. $("#paymenAmountSum").html(data.PaymenAmountSum.toString());
  17. })
  18. }
  19. //获取选中的数据ID
  20. function validChoose() {
  21. var d = [];
  22. $.each($("#dgChargeTotalList").cmsXDataTable("getSelections"), function (index) {
  23. d.push(this.ClassID);
  24. });
  25. return d;
  26. }
  27. //设置列颜色为红色
  28. function SetRedColumn(index, row, value) {
  29. return " <span style=\"color: red;\">" + value + "</span>";
  30. }
  31. //Excel导出
  32. function ChargeTotal_Excel() {
  33. $("#formQuery").submit();
  34. }
  35. //联动查询
  36. function queryStandard(data) {
  37. queryClass();
  38. reload();
  39. }
  40. function queryCollege(data) {
  41. var campusID = $("#CampusDropdown").combogridX("getValue");
  42. var collegeID = $("#CollegeDropdown").combogridX("getValue");
  43. var jsonString = "({'QueryParamsDatas':'CampusDropdown|*|" + campusID + "|@|";
  44. jsonString += "CollegeDropdown|*|" + collegeID + "|@|'})";
  45. $("#CollegeDropdown").combogridX("reload", eval(jsonString));
  46. $("#StandardDictionaryDropDown").combogridX("reload", eval(jsonString));
  47. queryClass();
  48. reload();
  49. }
  50. function queryClass() {
  51. var jsonString = "";
  52. var parameterString = "";
  53. var campusID = $("#CampusDropdown").combogridX("getValue");
  54. var collegeID = $("#CollegeDropdown").combogridX("getValue");
  55. var educationID = $("#DictionaryEducation").combobox("getValue");
  56. var schoolYearID = $("#SchoolyearDictionaryDropDown").combobox("getValue");
  57. var standardID = $("#StandardDictionaryDropDown").combogridX("getValue");
  58. var learningFormID = $("#DictionaryLearningform").combobox("getValue");
  59. if (campusID != nonSelect) parameterString += "CampusDropdown|*|" + campusID + "|@|";
  60. if (collegeID != nonSelect) parameterString += "CollegeDropdown|*|" + collegeID + "|@|";
  61. if (educationID != nonSelect) parameterString += "DictionaryEducation|*|" + educationID + "|@|";
  62. if (schoolYearID != nonSelect) parameterString += "DictionaryGrade|*|" + schoolYearID + "|@|";
  63. if (standardID != nonSelect) parameterString += "DictionaryStandard|*|" + standardID + "|@|";
  64. if (learningFormID != nonSelect) parameterString += "DictionaryLearningform|*|" + learningFormID + "|@|";
  65. if (parameterString != "") {
  66. jsonString = "({'QueryParamsDatas':'" + parameterString + "'})";
  67. $("#StandardDictionaryDropDown").combogridX("reload", eval(jsonString));
  68. } else {
  69. $("#StandardDictionaryDropDown").combogridX("reload");
  70. }
  71. reload();
  72. }