ClubCourseBatchAdd.js 1.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  1. //刷新
  2. function reload() {
  3. $("#dgCourseNoClubList").cmsXDataTable("load", $.getDataGridParams("dgCourseNoClubList"));
  4. }
  5. //获取选中的数据
  6. function validChoose() {
  7. var d = [];
  8. $.each($("#dgCourseNoClubList").cmsXDataTable("getSelections"), function (index) {
  9. d.push(this);
  10. });
  11. return d;
  12. }
  13. //设置列颜色为红色
  14. function SetRedColumn(index, row, value) {
  15. return " <span style=\"color: red;\">" + value + "</span>";
  16. }
  17. //设置相应的行颜色为红色
  18. function SetRedGrid(rowIndex, rowData) {
  19. if (rowData.IsEnable != true) {
  20. return "color: red;";
  21. } else {
  22. return "";
  23. }
  24. }
  25. //确定生成成功后不关闭弹出页面
  26. function formSuccessReloadNoClose(data) {
  27. if (data.IsSuccess == true) {
  28. reload();
  29. }
  30. $.messager.alert("系统提示", data.Message);
  31. }
  32. //确定
  33. function ClubCourse_BatchAddConfirm() {
  34. var d = validChoose();
  35. if (d == "") {
  36. $.messager.alert("系统提示", "请选择您要新增的信息。");
  37. return;
  38. }
  39. $("#CourseNoClubList").val(JSON.stringify(d));
  40. $(document.forms[0]).submit();
  41. }