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.
 
 
 
 
 
 

207 lines
9.9 KiB

  1. /* * 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架(http://www.learun.cn)
  2. * Copyright (c) 2013-2020 力软信息技术(苏州)有限公司
  3. * 创建人:超级管理员
  4. * 日 期:2022-08-29 16:34
  5. * 描 述:毕业信息统计
  6. */
  7. var refreshGirdData;
  8. var bootstrap = function ($, learun) {
  9. "use strict";
  10. var page = {
  11. init: function () {
  12. page.initGird();
  13. page.bind();
  14. },
  15. bind: function () {
  16. $('#multiple_condition_query').lrMultipleQuery(function (queryJson) {
  17. page.search(queryJson);
  18. }, 300, 400);
  19. $('#MajorNo').lrDataSourceSelect({ code: 'CdMajorInfo', value: 'majorno', text: 'majorname' });
  20. $('#ClassNo').lrDataSourceSelect({ code: 'bjsj', value: 'classno', text: 'classname' });
  21. $('#GraduateGo').lrDataItemSelect({ code: 'GraduateGo' });
  22. $('#UniversityLevel').lrDataItemSelect({ code: 'GraduateLevel' });
  23. // 刷新
  24. $('#lr_refresh').on('click', function () {
  25. location.reload();
  26. });
  27. // 新增
  28. $('#lr_add').on('click', function () {
  29. learun.layerForm({
  30. id: 'form',
  31. title: '新增',
  32. url: top.$.rootUrl + '/EducationalAdministration/StuGraduateStatistic/Form',
  33. width: 800,
  34. height: 600,
  35. callBack: function (id) {
  36. return top[id].acceptClick(refreshGirdData);
  37. }
  38. });
  39. });
  40. // 编辑
  41. $('#lr_edit').on('click', function () {
  42. var keyValue = $('#gridtable').jfGridValue('Id');
  43. if (learun.checkrow(keyValue)) {
  44. learun.layerForm({
  45. id: 'form',
  46. title: '编辑',
  47. url: top.$.rootUrl + '/EducationalAdministration/StuGraduateStatistic/Form?keyValue=' + keyValue,
  48. width: 800,
  49. height: 600,
  50. callBack: function (id) {
  51. return top[id].acceptClick(refreshGirdData);
  52. }
  53. });
  54. }
  55. });
  56. // 删除
  57. $('#lr_delete').on('click', function () {
  58. var keyValue = $('#gridtable').jfGridValue('Id');
  59. if (learun.checkrow(keyValue)) {
  60. learun.layerConfirm('是否确认删除该项!', function (res) {
  61. if (res) {
  62. learun.deleteForm(top.$.rootUrl + '/EducationalAdministration/StuGraduateStatistic/DeleteForm', { keyValue: keyValue }, function () {
  63. refreshGirdData();
  64. });
  65. }
  66. });
  67. }
  68. });
  69. },
  70. // 初始化列表
  71. initGird: function () {
  72. $('#gridtable').lrAuthorizeJfGrid({
  73. url: top.$.rootUrl + '/EducationalAdministration/StuGraduateStatistic/GetPageList',
  74. headData: [
  75. { label: "学生编码", name: "StuNo", width: 100, align: "left" },
  76. { label: "姓名", name: "StuName", width: 100, align: "left" },
  77. {
  78. label: "性别", name: "GenderNo", width: 100, align: "left",
  79. formatter: function (cellvalue) {
  80. return cellvalue == true ? "男" : "女";
  81. }
  82. },
  83. { label: "身份证号", name: "IdentityCardNo", width: 150, align: "left" },
  84. { label: "学籍号", name: "StuCode", width: 100, align: "left" },
  85. { label: "学号", name: "ProvinceCode", width: 100, align: "left" },
  86. {
  87. label: "专业", name: "MajorNo", width: 100, align: "left",
  88. formatterAsync: function (callback, value, row, op, $cell) {
  89. learun.clientdata.getAsync('custmerData', {
  90. url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'CdMajorInfo',
  91. key: value,
  92. keyId: 'majorno',
  93. callback: function (_data) {
  94. callback(_data['majorname']);
  95. }
  96. });
  97. }
  98. },
  99. {
  100. label: "学制", name: "EduSystem", width: 100, align: "left",
  101. formatterAsync: function (callback, value, row, op, $cell) {
  102. learun.clientdata.getAsync('dataItem', {
  103. key: value,
  104. code: 'EduSystem',
  105. callback: function (_data) {
  106. callback(_data.text);
  107. }
  108. });
  109. }
  110. },
  111. {
  112. label: "班级", name: "ClassNo", width: 100, align: "left",
  113. formatterAsync: function (callback, value, row, op, $cell) {
  114. learun.clientdata.getAsync('custmerData', {
  115. url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'bjsj',
  116. key: value,
  117. keyId: 'classno',
  118. callback: function (_data) {
  119. callback(_data['classname']);
  120. }
  121. });
  122. }
  123. },
  124. { label: "联系电话", name: "mobile", width: 100, align: "left" },
  125. {
  126. label: "毕业去向", name: "GraduateGo", width: 200, align: "left",
  127. formatterAsync: function (callback, value, row, op, $cell) {
  128. learun.clientdata.getAsync('dataItem', {
  129. key: value,
  130. code: 'GraduateGo',
  131. callback: function (_data) {
  132. callback(_data.text);
  133. }
  134. });
  135. }
  136. },
  137. { label: "升入高校名称", name: "EnterUniversityName", width: 100, align: "left" },
  138. {
  139. label: "大学层次", name: "UniversityLevel", width: 100, align: "left",
  140. formatterAsync: function (callback, value, row, op, $cell) {
  141. learun.clientdata.getAsync('dataItem', {
  142. key: value,
  143. code: 'GraduateLevel',
  144. callback: function (_data) {
  145. callback(_data.text);
  146. }
  147. });
  148. }
  149. },
  150. { label: "就业单位名称", name: "EmployerName", width: 100, align: "left" },
  151. {
  152. label: "就业单位所属省", name: "EmployerProvince", width: 100, align: "left",
  153. formatterAsync: function (callback, value, row, op, $cell) {
  154. learun.clientdata.getAsync('custmerData', {
  155. url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'DIC_PROVINCE',
  156. key: value,
  157. keyId: 'pcode',
  158. callback: function (_data) {
  159. callback(_data['pname']);
  160. }
  161. });
  162. }
  163. },
  164. {
  165. label: "就业单位所属市", name: "EmployerCity", width: 100, align: "left",
  166. formatterAsync: function (callback, value, row, op, $cell) {
  167. learun.clientdata.getAsync('custmerData', {
  168. url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'DIC_CITY',
  169. key: value,
  170. keyId: 'ccode',
  171. callback: function (_data) {
  172. callback(_data['cname']);
  173. }
  174. });
  175. }
  176. },
  177. {
  178. label: "就业单位所属县(区)", name: "EmployerCountry", width: 150, align: "left",
  179. formatterAsync: function (callback, value, row, op, $cell) {
  180. learun.clientdata.getAsync('custmerData', {
  181. url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'DIC_AREA',
  182. key: value,
  183. keyId: 'acode',
  184. callback: function (_data) {
  185. callback(_data['aname']);
  186. }
  187. });
  188. }
  189. },
  190. { label: "备注", name: "Remark", width: 100, align: "left" },
  191. ],
  192. mainId: 'Id',
  193. isPage: true
  194. });
  195. page.search();
  196. },
  197. search: function (param) {
  198. param = param || {};
  199. $('#gridtable').jfGridSet('reload', { queryJson: JSON.stringify(param) });
  200. }
  201. };
  202. refreshGirdData = function () {
  203. $('#gridtable').jfGridSet('reload');
  204. };
  205. page.init();
  206. }