You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

122 lines
5.5 KiB

  1. var refreshGirdData;
  2. var ClassNo = request("ClassNo");
  3. var bootstrap = function ($, learun) {
  4. "use strict";
  5. var page = {
  6. init: function () {
  7. page.initGird();
  8. page.bind();
  9. },
  10. bind: function () {
  11. $('#multiple_condition_query').lrMultipleQuery(function (queryJson) {
  12. page.search(queryJson);
  13. }, 220, 400);
  14. // 刷新
  15. $('#lr_refresh').on('click',
  16. function () {
  17. location.reload();
  18. });
  19. var iframeIndex = top.layer.getFrameIndex(window.name);
  20. $('#lr_export').on('click', function () {
  21. //item = $btn[0].dfop;
  22. learun.layerForm({
  23. id: "ExcelExportForm",
  24. title: '导出Excel数据',
  25. url: top.$.rootUrl + '/Utility/ExcelExportForm?gridId=gridtableStu&filename=' + encodeURI(encodeURI('大厂新生导出')) + '&iframeIndex=' + iframeIndex,
  26. width: 500,
  27. height: 380,
  28. callBack: function (id) {
  29. return top[id].acceptClick();
  30. },
  31. btn: ['导出Excel', '关闭']
  32. });
  33. });
  34. },
  35. // 初始化列表
  36. initGird: function () {
  37. $('#gridtableStu').jfGrid({
  38. url: top.$.rootUrl + '/EducationalAdministration/StuInfoFresh/GetPageList',
  39. headData: [
  40. {
  41. label: '报名日期', name: 'SignUpTime', width: 150, align: "left", formatter: function (value) {
  42. return /\d{4}-\d{1,2}-\d{1,2}/g.exec(value);
  43. }
  44. },
  45. { label: '姓名', name: 'StuName', width: 100, align: "left" },
  46. {
  47. label: '性别', name: 'GenderNo', width: 80, align: "left", formatterAsync: function (callback, value, row, op, $cell) {
  48. learun.clientdata.getAsync('dataItem', {
  49. key: value,
  50. code: 'usersex',
  51. callback: function (_data) {
  52. callback(_data.text);
  53. }
  54. });
  55. }
  56. },
  57. {
  58. label: '民族', name: 'NationalityNo', width: 80, align: "left", formatterAsync: function (callback, value, row, op, $cell) {
  59. learun.clientdata.getAsync('dataItem', {
  60. key: value,
  61. code: 'National',
  62. callback: function (_data) {
  63. callback(_data.text);
  64. }
  65. });
  66. }
  67. },
  68. { label: '毕业学校', name: 'HighSchoolName', width: 150, align: "left" },
  69. { label: '中学班级', name: 'OldClassName', width: 100, align: "left" },
  70. { label: '中考成绩', name: 'ComprehensiveScore', width: 150, align: "left" },
  71. { label: '家庭住址', name: 'FamilyAddress', width: 150, align: "left" },
  72. { label: '户口所在地', name: 'OriginAddress', width: 150, align: "left" },
  73. { label: '身份证号', name: 'IdentityCardNo', width: 150, align: "left" },
  74. { label: '家长电话', name: 'telephone', width: 150, align: "left" },
  75. {
  76. label: '选报专业', name: 'MajorNo', width: 100, align: "left", formatterAsync: function (callback, value, row, op, $cell) {
  77. learun.clientdata.getAsync('custmerData', {
  78. url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'CdMajorInfo',
  79. key: value,
  80. keyId: 'majorno',
  81. callback: function (_data) {
  82. callback(_data['majorname']);
  83. }
  84. });
  85. }
  86. },
  87. { label: '学制', name: 'EducationalSystem', width: 100, align: "left" },
  88. {
  89. label: "是否住宿", name: "IsAccommodate", width: 100, align: "left",
  90. formatterAsync: function (callback, value, row, op, $cell) {
  91. learun.clientdata.getAsync('dataItem', {
  92. key: value,
  93. code: 'YesOrNoInt',
  94. callback: function (_data) {
  95. callback(_data.text);
  96. }
  97. });
  98. }
  99. },
  100. { label: "身高/体重", name: "HeightWeight", width: 100, align: "left" },
  101. ],
  102. mainId: 'ID',
  103. isPage: true,
  104. sidx: 'StuNo',
  105. sord: 'desc'
  106. });
  107. page.search();
  108. },
  109. search: function (param) {
  110. param = param || {};
  111. param.ClassNo = ClassNo;
  112. $('#gridtableStu').jfGridSet('reload', { queryJson: JSON.stringify(param) });
  113. }
  114. };
  115. refreshGirdData = function () {
  116. page.search();
  117. };
  118. page.init();
  119. }