25'ten fazla konu seçemezsiniz Konular bir harf veya rakamla başlamalı, kısa çizgiler ('-') içerebilir ve en fazla 35 karakter uzunluğunda olabilir.

Index.js 15 KiB

4 yıl önce
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271
  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('custmerData', {
  114. url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'BCdNationality',
  115. key: value,
  116. keyId: 'nationalityno',
  117. callback: function (_data) {
  118. callback(_data['nationality']);
  119. }
  120. });
  121. }
  122. },
  123. {
  124. label: '文化程度', name: 'CultureDegreeNo', width: 100, align: "left",
  125. formatterAsync: function (callback, value, row, op, $cell) {
  126. learun.clientdata.getAsync('custmerData', {
  127. url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'BCdCultureDegree',
  128. key: value,
  129. keyId: 'culturedegreeno',
  130. callback: function (_data) {
  131. callback(_data['culturedegree']);
  132. }
  133. });
  134. }
  135. },
  136. { label: '父亲姓名', name: 'FatherName', width: 100, align: "left" },
  137. { label: '父亲身份证号', name: 'FatherIdCard', width: 100, align: "left" },
  138. { label: '父亲电话', name: 'FatherPhone', width: 100, align: "left" },
  139. { label: '母亲姓名', name: 'MotherName', width: 100, align: "left" },
  140. { label: '母亲身份证号', name: 'MotherIdCard', width: 100, align: "left" },
  141. { label: '母亲电话', name: 'MotherPhone', width: 100, align: "left" },
  142. {
  143. label: '受教情况', name: 'TeachSituation', width: 100, align: "left", formatterAsync: function (callback, value, row, op, $cell) {
  144. learun.clientdata.getAsync('dataItem', {
  145. key: value,
  146. code: 'TeachSituation',
  147. callback: function (_data) {
  148. callback(_data.text);
  149. }
  150. });
  151. }
  152. },
  153. { label: '工作单位', name: 'WorkUnits', width: 100, align: "left" },
  154. { label: '联系电话', name: 'Phone', width: 100, align: "left" },
  155. {
  156. label: '健康状况', name: 'HealthType', width: 100, align: "left", formatterAsync: function (callback, value, row, op, $cell) {
  157. learun.clientdata.getAsync('dataItem', {
  158. key: value,
  159. code: 'StuHealthType',
  160. callback: function (_data) {
  161. callback(_data.text);
  162. }
  163. });
  164. }
  165. },
  166. { label: '残疾类型', name: 'DisableType', width: 100, align: "left" },
  167. {
  168. label: '政治面貌', name: 'PartyFaceNo', width: 100, align: "left",
  169. formatterAsync: function (callback, value, row, op, $cell) {
  170. learun.clientdata.getAsync('custmerData', {
  171. url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'BCdPartyFace',
  172. key: value,
  173. keyId: 'partyfaceno',
  174. callback: function (_data) {
  175. callback(_data['partyface']);
  176. }
  177. });
  178. }
  179. },
  180. { label: '主业', name: 'MainBusiness', width: 100, align: "left" },
  181. { label: '备注', name: 'Remark', width: 100, align: "left" },
  182. { label: '原县', name: 'OriginalCountry', width: 100, align: "left" },
  183. { label: '原乡镇', name: 'OriginalVillage', width: 100, align: "left" },
  184. { label: '原学校', name: 'OriginalSchool', width: 100, align: "left" },
  185. { label: '原年级', name: 'OriginalGrade', width: 100, align: "left" },
  186. { label: '原班主任', name: 'OriginalTeacher', width: 100, align: "left" },
  187. { label: '原班主任电话', name: 'OriginalTeacherPhone', width: 100, align: "left" },
  188. { label: '原班级', name: 'OriginalClass', width: 100, align: "left" },
  189. { label: '原班级类别', name: 'OriginalClassType', width: 100, align: "left" },
  190. {
  191. label: '原就读方式', name: 'OriginalStudyWay', width: 100, align: "left", formatterAsync: function (callback, value, row, op, $cell) {
  192. learun.clientdata.getAsync('dataItem', {
  193. key: value,
  194. code: 'StudyWay',
  195. callback: function (_data) {
  196. callback(_data.text);
  197. }
  198. });
  199. }
  200. },
  201. {
  202. label: '原学段', name: 'OriginalStudyPeriod', width: 100, align: "left", formatterAsync: function (callback, value, row, op, $cell) {
  203. learun.clientdata.getAsync('dataItem', {
  204. key: value,
  205. code: 'StudyPeriod',
  206. callback: function (_data) {
  207. callback(_data.text);
  208. }
  209. });
  210. }
  211. },
  212. { label: '原学生状态', name: 'OriginalStudentStatus', width: 100, align: "left" },
  213. { label: '省', name: 'Province', width: 100, align: "left" },
  214. { label: '地区', name: 'Area', width: 100, align: "left" },
  215. { label: '县', name: 'Country', width: 100, align: "left" },
  216. { label: '乡镇', name: 'Village', width: 100, align: "left" },
  217. { label: '村', name: 'Hamlet', width: 100, align: "left" },
  218. { label: '组', name: 'Groups', width: 100, align: "left" },
  219. { label: '门号', name: 'DoorNum', width: 100, align: "left" },
  220. { label: '新疆学籍', name: 'XinJiangStatus', width: 100, align: "left" },
  221. { label: '在读县', name: 'ReadCountry', width: 100, align: "left" },
  222. { label: '在读乡镇', name: 'ReadVillage', width: 100, align: "left" },
  223. { label: '在读学校', name: 'ReadSchool', width: 100, align: "left" },
  224. {
  225. label: '在读学段', name: 'ReadStudyPeriod', width: 100, align: "left", formatterAsync: function (callback, value, row, op, $cell) {
  226. learun.clientdata.getAsync('dataItem', {
  227. key: value,
  228. code: 'StudyPeriod',
  229. callback: function (_data) {
  230. callback(_data.text);
  231. }
  232. });
  233. }
  234. },
  235. { label: '在读年级', name: 'ReadGrade', width: 100, align: "left" },
  236. { label: '科类', name: 'DivisionType', width: 100, align: "left" },
  237. { label: '计划类型', name: 'PlanType', width: 100, align: "left" },
  238. { label: '入学时间', name: 'AdmissionTime', width: 100, align: "left" },
  239. { label: '在读班主任', name: 'ReadTeacher', width: 100, align: "left" },
  240. { label: '在读班主任电话', name: 'ReadTeacherPhone', width: 100, align: "left" },
  241. { label: '在读班级', name: 'ReadClass', width: 100, align: "left" },
  242. { label: '毕业证号', name: 'GraduateNo', width: 100, align: "left" },
  243. { label: '在读班级类别', name: 'ReadClassType', width: 100, align: "left" },
  244. {
  245. label: '在读就读方式', name: 'ReadStudyWay', width: 100, align: "left", formatterAsync: function (callback, value, row, op, $cell) {
  246. learun.clientdata.getAsync('dataItem', {
  247. key: value,
  248. code: 'StudyWay',
  249. callback: function (_data) {
  250. callback(_data.text);
  251. }
  252. });
  253. }
  254. },
  255. { label: '在读学生状态', name: 'ReadStudentStatus', width: 100, align: "left" },
  256. ],
  257. mainId: 'id',
  258. isPage: true
  259. });
  260. page.search();
  261. },
  262. search: function (param) {
  263. param = param || {};
  264. $('#gridtable').jfGridSet('reload', { queryJson: JSON.stringify(param) });
  265. }
  266. };
  267. refreshGirdData = function () {
  268. page.search();
  269. };
  270. page.init();
  271. }