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.
 
 
 
 
 
 

270 lines
15 KiB

  1. /* * 版 本 Learun-ADMS-Ultimate V7.0.0 数字化智慧校园(http://www.learun.cn)
  2. * Copyright (c) 2013-2018 北京泉江科技有限公司
  3. * 创建人:超级管理员
  4. * 日 期:2020-05-18 14:35
  5. * 描 述:学籍信息管理
  6. */
  7. var selectedRow;
  8. var refreshGirdData;
  9. var bootstrap = function ($, learun) {
  10. "use strict";
  11. var page = {
  12. init: function () {
  13. page.initGird();
  14. page.bind();
  15. },
  16. bind: function () {
  17. // 查询
  18. $('#multiple_condition_query').lrMultipleQuery(function (queryJson) {
  19. page.search(queryJson);
  20. }, 350, 400);
  21. $("#ResidenceNo").lrDataItemSelect({ code: 'ResidenceNo' });
  22. $('#CultureDegreeNo').lrDataSourceSelect({ code: 'BCdCultureDegree', value: 'culturedegreeno', text: 'culturedegree' });
  23. $("#TeachSituation").lrDataItemSelect({ code: 'TeachSituation' });
  24. $("#HealthType").lrDataItemSelect({ code: 'StuHealthType' });
  25. $("#ReadStudyWay").lrDataItemSelect({ code: 'StudyWay' });
  26. $("#ReadStudyPeriod").lrDataItemSelect({ code: 'StudyPeriod' });
  27. // 刷新
  28. $('#lr_refresh').on('click', function () {
  29. location.reload();
  30. });
  31. // 新增
  32. $('#lr_add').on('click', function () {
  33. selectedRow = null;
  34. learun.layerForm({
  35. id: 'form',
  36. title: '新增',
  37. url: top.$.rootUrl + '/EducationalAdministration/StuInfoBasicTwo/Form',
  38. width: 700,
  39. height: 400,
  40. callBack: function (id) {
  41. return top[id].acceptClick(refreshGirdData);
  42. }
  43. });
  44. });
  45. // 编辑
  46. $('#lr_edit').on('click', function () {
  47. var keyValue = $('#gridtable').jfGridValue('id');
  48. selectedRow = $('#gridtable').jfGridGet('rowdata');
  49. if (learun.checkrow(keyValue)) {
  50. learun.layerForm({
  51. id: 'form',
  52. title: '编辑',
  53. url: top.$.rootUrl + '/EducationalAdministration/StuInfoBasicTwo/Form?keyValue=' + keyValue,
  54. width: 700,
  55. height: 400,
  56. callBack: function (id) {
  57. return top[id].acceptClick(refreshGirdData);
  58. }
  59. });
  60. }
  61. });
  62. // 删除
  63. $('#lr_delete').on('click', function () {
  64. var keyValue = $('#gridtable').jfGridValue('id');
  65. if (learun.checkrow(keyValue)) {
  66. learun.layerConfirm('是否确认删除该项!', function (res) {
  67. if (res) {
  68. learun.deleteForm(top.$.rootUrl + '/EducationalAdministration/StuInfoBasicTwo/DeleteForm', { keyValue: keyValue }, function () {
  69. });
  70. }
  71. });
  72. }
  73. });
  74. },
  75. initGird: function () {
  76. $('#gridtable').lrAuthorizeJfGrid({
  77. url: top.$.rootUrl + '/EducationalAdministration/StuInfoBasicTwo/GetPageList',
  78. headData: [
  79. { label: '学号', name: 'StuNo', width: 100, align: "left" },
  80. { label: '姓名', name: 'StuName', width: 100, align: "left" },
  81. { label: '身份证号', name: 'IdCard', width: 100, align: "left" },
  82. { label: '出生日期', name: 'Birthday', width: 100, align: "left" },
  83. { label: '毕业时间', name: 'GraduateDate', width: 100, align: "left" },
  84. { label: '年龄', name: 'Age', width: 100, align: "left" },
  85. {
  86. label: '性别', name: 'Sex', width: 100, align: "left", formatterAsync: function (callback, value, row, op, $cell) {
  87. learun.clientdata.getAsync('dataItem', {
  88. key: value,
  89. code: 'usersex',
  90. callback: function (_data) {
  91. callback(_data.text);
  92. }
  93. });
  94. }
  95. },
  96. { label: '户口本号', name: 'HuKouPaperNum', width: 100, align: "left" },
  97. { label: '户籍地', name: 'OriginAddress', width: 100, align: "left" },
  98. {
  99. label: '户口性质', name: 'ResidenceNo', width: 100, align: "left", formatterAsync: function (callback, value, row, op, $cell) {
  100. learun.clientdata.getAsync('dataItem', {
  101. key: value,
  102. code: 'ResidenceNo',
  103. callback: function (_data) {
  104. callback(_data.text);
  105. }
  106. });
  107. }
  108. },
  109. { label: '与户主关系', name: 'FamilyRelation', width: 100, align: "left" },
  110. {
  111. label: '民族', name: 'NationalityNo', width: 100, align: "left",
  112. formatterAsync: function (callback, value, row, op, $cell) {
  113. learun.clientdata.getAsync('dataItem', {
  114. key: value,
  115. code: 'National',
  116. callback: function (_data) {
  117. callback(_data.text);
  118. }
  119. });
  120. }
  121. },
  122. {
  123. label: '文化程度', name: 'CultureDegreeNo', width: 100, align: "left",
  124. formatterAsync: function (callback, value, row, op, $cell) {
  125. learun.clientdata.getAsync('custmerData', {
  126. url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'BCdCultureDegree',
  127. key: value,
  128. keyId: 'culturedegreeno',
  129. callback: function (_data) {
  130. callback(_data['culturedegree']);
  131. }
  132. });
  133. }
  134. },
  135. { label: '父亲姓名', name: 'FatherName', width: 100, align: "left" },
  136. { label: '父亲身份证号', name: 'FatherIdCard', width: 100, align: "left" },
  137. { label: '父亲电话', name: 'FatherPhone', width: 100, align: "left" },
  138. { label: '母亲姓名', name: 'MotherName', width: 100, align: "left" },
  139. { label: '母亲身份证号', name: 'MotherIdCard', width: 100, align: "left" },
  140. { label: '母亲电话', name: 'MotherPhone', width: 100, align: "left" },
  141. {
  142. label: '受教情况', name: 'TeachSituation', width: 100, align: "left", formatterAsync: function (callback, value, row, op, $cell) {
  143. learun.clientdata.getAsync('dataItem', {
  144. key: value,
  145. code: 'TeachSituation',
  146. callback: function (_data) {
  147. callback(_data.text);
  148. }
  149. });
  150. }
  151. },
  152. { label: '工作单位', name: 'WorkUnits', width: 100, align: "left" },
  153. { label: '联系电话', name: 'Phone', width: 100, align: "left" },
  154. {
  155. label: '健康状况', name: 'HealthType', width: 100, align: "left", formatterAsync: function (callback, value, row, op, $cell) {
  156. learun.clientdata.getAsync('dataItem', {
  157. key: value,
  158. code: 'StuHealthType',
  159. callback: function (_data) {
  160. callback(_data.text);
  161. }
  162. });
  163. }
  164. },
  165. { label: '残疾类型', name: 'DisableType', width: 100, align: "left" },
  166. {
  167. label: '政治面貌', name: 'PartyFaceNo', width: 100, align: "left",
  168. formatterAsync: function (callback, value, row, op, $cell) {
  169. learun.clientdata.getAsync('dataItem', {
  170. key: value,
  171. code: 'BCdPartyFace',
  172. callback: function (_data) {
  173. callback(_data.text);
  174. }
  175. });
  176. }
  177. },
  178. { label: '主业', name: 'MainBusiness', width: 100, align: "left" },
  179. { label: '备注', name: 'Remark', width: 100, align: "left" },
  180. { label: '原县', name: 'OriginalCountry', width: 100, align: "left" },
  181. { label: '原乡镇', name: 'OriginalVillage', width: 100, align: "left" },
  182. { label: '原学校', name: 'OriginalSchool', width: 100, align: "left" },
  183. { label: '原年级', name: 'OriginalGrade', width: 100, align: "left" },
  184. { label: '原班主任', name: 'OriginalTeacher', width: 100, align: "left" },
  185. { label: '原班主任电话', name: 'OriginalTeacherPhone', width: 100, align: "left" },
  186. { label: '原班级', name: 'OriginalClass', width: 100, align: "left" },
  187. { label: '原班级类别', name: 'OriginalClassType', width: 100, align: "left" },
  188. {
  189. label: '原就读方式', name: 'OriginalStudyWay', width: 100, align: "left", formatterAsync: function (callback, value, row, op, $cell) {
  190. learun.clientdata.getAsync('dataItem', {
  191. key: value,
  192. code: 'StudyWay',
  193. callback: function (_data) {
  194. callback(_data.text);
  195. }
  196. });
  197. }
  198. },
  199. {
  200. label: '原学段', name: 'OriginalStudyPeriod', width: 100, align: "left", formatterAsync: function (callback, value, row, op, $cell) {
  201. learun.clientdata.getAsync('dataItem', {
  202. key: value,
  203. code: 'StudyPeriod',
  204. callback: function (_data) {
  205. callback(_data.text);
  206. }
  207. });
  208. }
  209. },
  210. { label: '原学生状态', name: 'OriginalStudentStatus', width: 100, align: "left" },
  211. { label: '省', name: 'Province', width: 100, align: "left" },
  212. { label: '地区', name: 'Area', width: 100, align: "left" },
  213. { label: '县', name: 'Country', width: 100, align: "left" },
  214. { label: '乡镇', name: 'Village', width: 100, align: "left" },
  215. { label: '村', name: 'Hamlet', width: 100, align: "left" },
  216. { label: '组', name: 'Groups', width: 100, align: "left" },
  217. { label: '门号', name: 'DoorNum', width: 100, align: "left" },
  218. { label: '新疆学籍', name: 'XinJiangStatus', width: 100, align: "left" },
  219. { label: '在读县', name: 'ReadCountry', width: 100, align: "left" },
  220. { label: '在读乡镇', name: 'ReadVillage', width: 100, align: "left" },
  221. { label: '在读学校', name: 'ReadSchool', width: 100, align: "left" },
  222. {
  223. label: '在读学段', name: 'ReadStudyPeriod', width: 100, align: "left", formatterAsync: function (callback, value, row, op, $cell) {
  224. learun.clientdata.getAsync('dataItem', {
  225. key: value,
  226. code: 'StudyPeriod',
  227. callback: function (_data) {
  228. callback(_data.text);
  229. }
  230. });
  231. }
  232. },
  233. { label: '在读年级', name: 'ReadGrade', width: 100, align: "left" },
  234. { label: '科类', name: 'DivisionType', width: 100, align: "left" },
  235. { label: '计划类型', name: 'PlanType', width: 100, align: "left" },
  236. { label: '入学时间', name: 'AdmissionTime', width: 100, align: "left" },
  237. { label: '在读班主任', name: 'ReadTeacher', width: 100, align: "left" },
  238. { label: '在读班主任电话', name: 'ReadTeacherPhone', width: 100, align: "left" },
  239. { label: '在读班级', name: 'ReadClass', width: 100, align: "left" },
  240. { label: '毕业证号', name: 'GraduateNo', width: 100, align: "left" },
  241. { label: '在读班级类别', name: 'ReadClassType', width: 100, align: "left" },
  242. {
  243. label: '在读就读方式', name: 'ReadStudyWay', width: 100, align: "left", formatterAsync: function (callback, value, row, op, $cell) {
  244. learun.clientdata.getAsync('dataItem', {
  245. key: value,
  246. code: 'StudyWay',
  247. callback: function (_data) {
  248. callback(_data.text);
  249. }
  250. });
  251. }
  252. },
  253. { label: '在读学生状态', name: 'ReadStudentStatus', width: 100, align: "left" },
  254. ],
  255. mainId: 'id',
  256. isPage: true
  257. });
  258. page.search();
  259. },
  260. search: function (param) {
  261. param = param || {};
  262. $('#gridtable').jfGridSet('reload', { queryJson: JSON.stringify(param) });
  263. }
  264. };
  265. refreshGirdData = function () {
  266. page.search();
  267. };
  268. page.init();
  269. }