dlt-for-react 1.0.23 → 1.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (213) hide show
  1. package/README.md +12 -2
  2. package/lib/components/Button/index.js +79 -0
  3. package/lib/components/HqSelector/HqLsrySelector/index.js +3 -5
  4. package/lib/components/HqSelector/HqRySelector/index.js +3 -5
  5. package/lib/components/HqSelector/HqWzSelector/index.js +3 -5
  6. package/lib/components/KyEditableTable/component.js +3 -5
  7. package/lib/components/KyEditableTable/index.js +7 -13
  8. package/lib/components/KyExcel/index.js +3 -5
  9. package/lib/components/KyInputPicker/render.js +13 -43
  10. package/lib/components/KyInputPicker/setting-checkbox.js +3 -5
  11. package/lib/components/KyInputPicker/setting-multiSelect.js +3 -5
  12. package/lib/components/KyInputPicker/setting-nhcascader.js +3 -5
  13. package/lib/components/KyInputPicker/setting-select.js +3 -5
  14. package/lib/components/KyInputPicker/setting-stu-selector.js +3 -5
  15. package/lib/components/KyInputPicker/setting-tea-selector.js +3 -5
  16. package/lib/components/KyTable/checkButtons.js +4 -7
  17. package/lib/components/KyTree/index.js +6 -16
  18. package/lib/components/KyUpload/index.js +13 -21
  19. package/lib/components/NHAuditPanel/config/Axios.js +263 -0
  20. package/lib/components/NHAuditPanel/config/api.js +479 -0
  21. package/lib/components/NHAuditPanel/config/data.js +156 -0
  22. package/lib/components/NHAuditPanel/config/typeMap.js +1234 -0
  23. package/lib/components/NHAuditPanel/config/uiValidate.js +92 -0
  24. package/lib/components/NHAuditPanel/index.js +413 -0
  25. package/lib/components/NHAuditPanel/node.js +619 -0
  26. package/lib/components/NHCascader/index.js +355 -0
  27. package/lib/components/NHCheckboxGroup/index.js +135 -0
  28. package/lib/components/NHDynamicFormShow/baseInfo/index.js +194 -0
  29. package/lib/components/NHDynamicFormShow/custom/index.js +553 -0
  30. package/lib/components/NHDynamicFormShow/customModule/common/CommonMethod.js +43 -0
  31. package/lib/components/NHDynamicFormShow/customModule/czxy/qgzx/EditForm.js +1113 -0
  32. package/lib/components/NHDynamicFormShow/customModule/czxy/qgzx/index.js +263 -0
  33. package/lib/components/NHDynamicFormShow/customModule/czxy/xfjm/EditForm.js +880 -0
  34. package/lib/components/NHDynamicFormShow/customModule/czxy/xfjm/index.js +171 -0
  35. package/lib/components/NHDynamicFormShow/customModule/czxy/zxj/EditForm.js +865 -0
  36. package/lib/components/NHDynamicFormShow/customModule/czxy/zxj/index.js +138 -0
  37. package/lib/components/NHDynamicFormShow/customModule/eszy/zsxxhd/EditForm.js +571 -0
  38. package/lib/components/NHDynamicFormShow/customModule/eszy/zsxxhd/index.js +147 -0
  39. package/lib/components/NHDynamicFormShow/customModule/eszy/zybjtz/EditForm.js +474 -0
  40. package/lib/components/NHDynamicFormShow/customModule/eszy/zybjtz/index.js +139 -0
  41. package/lib/components/NHDynamicFormShow/customModule/gnyxy/cqzg/EditForm.js +506 -0
  42. package/lib/components/NHDynamicFormShow/customModule/gnyxy/cqzg/index.js +143 -0
  43. package/lib/components/NHDynamicFormShow/customModule/gnyxy/gwsb/EditForm.js +1074 -0
  44. package/lib/components/NHDynamicFormShow/customModule/gnyxy/gwsb/index.js +172 -0
  45. package/lib/components/NHDynamicFormShow/customModule/gnyxy/qjgl/EditForm.js +927 -0
  46. package/lib/components/NHDynamicFormShow/customModule/gnyxy/qjgl/index.js +195 -0
  47. package/lib/components/NHDynamicFormShow/customModule/gnyxy/sxsqj/EditForm.js +1064 -0
  48. package/lib/components/NHDynamicFormShow/customModule/gnyxy/sxsqj/index.js +183 -0
  49. package/lib/components/NHDynamicFormShow/customModule/hblgxy/jxj/EditForm.js +763 -0
  50. package/lib/components/NHDynamicFormShow/customModule/hblgxy/jxj/index.js +137 -0
  51. package/lib/components/NHDynamicFormShow/customModule/hblgxy/lzjxj/EditForm.js +819 -0
  52. package/lib/components/NHDynamicFormShow/customModule/hblgxy/lzjxj/index.js +137 -0
  53. package/lib/components/NHDynamicFormShow/customModule/hblgxy/qgzx/EditForm.js +700 -0
  54. package/lib/components/NHDynamicFormShow/customModule/hblgxy/qgzx/index.js +162 -0
  55. package/lib/components/NHDynamicFormShow/customModule/hblgxy/xsqj/EditForm.js +743 -0
  56. package/lib/components/NHDynamicFormShow/customModule/hblgxy/xsqj/index.js +177 -0
  57. package/lib/components/NHDynamicFormShow/customModule/hblgxy/zxj/EditForm.js +848 -0
  58. package/lib/components/NHDynamicFormShow/customModule/hblgxy/zxj/index.js +138 -0
  59. package/lib/components/NHDynamicFormShow/customModule/hljwgy/qjgl/EditForm.js +777 -0
  60. package/lib/components/NHDynamicFormShow/customModule/hljwgy/qjgl/index.js +161 -0
  61. package/lib/components/NHDynamicFormShow/customModule/hljwgy/xjgl/EditForm.js +706 -0
  62. package/lib/components/NHDynamicFormShow/customModule/hljwgy/xjgl/index.js +130 -0
  63. package/lib/components/NHDynamicFormShow/customModule/jhysxy/cfjcsq/cfjcEditForm.js +413 -0
  64. package/lib/components/NHDynamicFormShow/customModule/jhysxy/cfjcsq/index.js +135 -0
  65. package/lib/components/NHDynamicFormShow/customModule/jhysxy/xsqj/EditForm.js +1013 -0
  66. package/lib/components/NHDynamicFormShow/customModule/jhysxy/xsqj/index.js +175 -0
  67. package/lib/components/NHDynamicFormShow/customModule/jjrlx/EditForm.js +1345 -0
  68. package/lib/components/NHDynamicFormShow/customModule/jjrlx/index.js +274 -0
  69. package/lib/components/NHDynamicFormShow/customModule/jxj/EditForm.js +669 -0
  70. package/lib/components/NHDynamicFormShow/customModule/jxj/index.js +134 -0
  71. package/lib/components/NHDynamicFormShow/customModule/jxsl/fqkns/EditForm.js +378 -0
  72. package/lib/components/NHDynamicFormShow/customModule/jxsl/fqkns/index.js +120 -0
  73. package/lib/components/NHDynamicFormShow/customModule/jxsl/xwryfjjd/EditForm.js +638 -0
  74. package/lib/components/NHDynamicFormShow/customModule/jxsl/xwryfjjd/index.js +133 -0
  75. package/lib/components/NHDynamicFormShow/customModule/qgzx/EditForm.js +965 -0
  76. package/lib/components/NHDynamicFormShow/customModule/qgzx/index.js +237 -0
  77. package/lib/components/NHDynamicFormShow/customModule/qjgl/EditForm.js +823 -0
  78. package/lib/components/NHDynamicFormShow/customModule/qjgl/index.js +188 -0
  79. package/lib/components/NHDynamicFormShow/customModule/rcgl/jqlssq/EditForm.js +401 -0
  80. package/lib/components/NHDynamicFormShow/customModule/rcgl/jqlssq/index.js +472 -0
  81. package/lib/components/NHDynamicFormShow/customModule/rcgl/tssq/EditForm.js +304 -0
  82. package/lib/components/NHDynamicFormShow/customModule/rcgl/tssq/NHCascader/index.js +375 -0
  83. package/lib/components/NHDynamicFormShow/customModule/rcgl/tssq/NHInputPicker/RadioGroup.js +118 -0
  84. package/lib/components/NHDynamicFormShow/customModule/rcgl/tssq/NHInputPicker/index.js +62 -0
  85. package/lib/components/NHDynamicFormShow/customModule/rcgl/tssq/NHInputPicker/input-const.js +55 -0
  86. package/lib/components/NHDynamicFormShow/customModule/rcgl/tssq/NHInputPicker/render.js +1238 -0
  87. package/lib/components/NHDynamicFormShow/customModule/rcgl/tssq/index.js +375 -0
  88. package/lib/components/NHDynamicFormShow/customModule/rych/collective/EditForm.js +554 -0
  89. package/lib/components/NHDynamicFormShow/customModule/rych/collective/index.js +130 -0
  90. package/lib/components/NHDynamicFormShow/customModule/rych/personal/EditForm.js +542 -0
  91. package/lib/components/NHDynamicFormShow/customModule/rych/personal/index.js +133 -0
  92. package/lib/components/NHDynamicFormShow/customModule/sxgy/rych/collective/EditForm.js +575 -0
  93. package/lib/components/NHDynamicFormShow/customModule/sxgy/rych/collective/index.js +130 -0
  94. package/lib/components/NHDynamicFormShow/customModule/sxgy/rych/personal/EditForm.js +563 -0
  95. package/lib/components/NHDynamicFormShow/customModule/sxgy/rych/personal/index.js +133 -0
  96. package/lib/components/NHDynamicFormShow/customModule/whcz/qjgl/EditForm.js +745 -0
  97. package/lib/components/NHDynamicFormShow/customModule/whcz/qjgl/index.js +164 -0
  98. package/lib/components/NHDynamicFormShow/customModule/whcz/rccrxy/EditForm.js +587 -0
  99. package/lib/components/NHDynamicFormShow/customModule/whcz/rccrxy/index.js +143 -0
  100. package/lib/components/NHDynamicFormShow/customModule/whdlqjgl/EditForm.js +743 -0
  101. package/lib/components/NHDynamicFormShow/customModule/whdlqjgl/index.js +172 -0
  102. package/lib/components/NHDynamicFormShow/customModule/whgc/jjrlx/EditForm.js +1410 -0
  103. package/lib/components/NHDynamicFormShow/customModule/whgc/jjrlx/index.js +274 -0
  104. package/lib/components/NHDynamicFormShow/customModule/whgc/jxj/EditForm.js +755 -0
  105. package/lib/components/NHDynamicFormShow/customModule/whgc/jxj/index.js +130 -0
  106. package/lib/components/NHDynamicFormShow/customModule/whgc/qjgl/EditForm.js +814 -0
  107. package/lib/components/NHDynamicFormShow/customModule/whgc/qjgl/index.js +188 -0
  108. package/lib/components/NHDynamicFormShow/customModule/whgc/zxj/EditForm.js +769 -0
  109. package/lib/components/NHDynamicFormShow/customModule/whgc/zxj/index.js +130 -0
  110. package/lib/components/NHDynamicFormShow/customModule/whgcrych/EditForm.js +1004 -0
  111. package/lib/components/NHDynamicFormShow/customModule/whgcrych/index.js +126 -0
  112. package/lib/components/NHDynamicFormShow/customModule/whtl/jsrzsq/EditForm.js +503 -0
  113. package/lib/components/NHDynamicFormShow/customModule/whtl/jsrzsq/index.js +149 -0
  114. package/lib/components/NHDynamicFormShow/customModule/whtlyhk/EditForm.js +379 -0
  115. package/lib/components/NHDynamicFormShow/customModule/whtlyhk/index.js +148 -0
  116. package/lib/components/NHDynamicFormShow/customModule/whtlzxj/EditForm.js +748 -0
  117. package/lib/components/NHDynamicFormShow/customModule/whtlzxj/index.js +135 -0
  118. package/lib/components/NHDynamicFormShow/customModule/whtlzy/jxj/EditForm.js +762 -0
  119. package/lib/components/NHDynamicFormShow/customModule/whtlzy/jxj/index.js +134 -0
  120. package/lib/components/NHDynamicFormShow/customModule/wjcf/cfjc/cfjcEditForm.js +682 -0
  121. package/lib/components/NHDynamicFormShow/customModule/wjcf/cfjc/index.js +135 -0
  122. package/lib/components/NHDynamicFormShow/customModule/wjcf/wjsb/index.js +152 -0
  123. package/lib/components/NHDynamicFormShow/customModule/wjcf/wjsb/wjsbEditForm.js +783 -0
  124. package/lib/components/NHDynamicFormShow/customModule/zxj/EditForm.js +764 -0
  125. package/lib/components/NHDynamicFormShow/customModule/zxj/index.js +138 -0
  126. package/lib/components/NHDynamicFormShow/customModule/zzsd/cfjcsq/cfjcEditForm.js +677 -0
  127. package/lib/components/NHDynamicFormShow/customModule/zzsd/cfjcsq/index.js +138 -0
  128. package/lib/components/NHDynamicFormShow/customModule/zzsd/qjgl/EditForm.js +1173 -0
  129. package/lib/components/NHDynamicFormShow/customModule/zzsd/qjgl/index.js +242 -0
  130. package/lib/components/NHDynamicFormShow/customModule/zzsd/rcgl/rcxwgrdj/IndividualRegistForm.js +862 -0
  131. package/lib/components/NHDynamicFormShow/customModule/zzsd/rcgl/rcxwgrdj/IndividualRegistIndex.js +201 -0
  132. package/lib/components/NHDynamicFormShow/customModule/zzsd/stuinfo/messageInfo.js +196 -0
  133. package/lib/components/NHDynamicFormShow/customModule/zzsd/wjsb/index.js +167 -0
  134. package/lib/components/NHDynamicFormShow/customModule/zzsd/wjsb/wjsbEditForm.js +1096 -0
  135. package/lib/components/NHDynamicFormShow/index.js +647 -0
  136. package/lib/components/NHDynamicFormShow/oneOnMany/cardForm/cardItem/index.js +279 -0
  137. package/lib/components/NHDynamicFormShow/oneOnMany/cardForm/index.js +206 -0
  138. package/lib/components/NHDynamicFormShow/oneOnMany/index.js +419 -0
  139. package/lib/components/NHDynamicFormShow/oneOnOne/EditForm.js +401 -0
  140. package/lib/components/NHDynamicFormShow/oneOnOne/index.js +271 -0
  141. package/lib/components/NHImagePicker/index.js +554 -0
  142. package/lib/components/NHInputPicker/RadioGroup.js +118 -0
  143. package/lib/components/NHInputPicker/index.js +62 -0
  144. package/lib/components/NHInputPicker/input-const.js +55 -0
  145. package/lib/components/NHInputPicker/render.js +1271 -0
  146. package/lib/components/NHListView/index.js +374 -0
  147. package/lib/components/NHMapGeolocation/index.js +537 -0
  148. package/lib/components/NHMapGeolocation/initMap/initGdMap.js +104 -0
  149. package/lib/components/NHMapGeolocation/initMap/initTencentMap.js +138 -0
  150. package/lib/components/NHMapGeolocation/style.js +51 -0
  151. package/lib/components/NHMultiSelect/index.js +272 -0
  152. package/lib/components/NHRadioGroup/index.js +118 -0
  153. package/lib/components/NHSelect/index.js +364 -0
  154. package/lib/components/NHTreeMenu/index.js +126 -0
  155. package/lib/components/NHTreeMenu/treeNode.js +164 -0
  156. package/lib/components/StuSelector/index.js +611 -0
  157. package/lib/index.js +161 -116
  158. package/lib/layouts/KyInputPicker/edit-page.js +585 -0
  159. package/lib/layouts/KyInputPicker/index.js +220 -0
  160. package/lib/layouts/KyInputPicker/input-const.js +134 -0
  161. package/lib/layouts/KyInputPicker/render.js +2477 -0
  162. package/lib/layouts/KyInputPicker/setting-checkbox.js +850 -0
  163. package/lib/layouts/KyInputPicker/setting-datepicker.js +430 -0
  164. package/lib/layouts/KyInputPicker/setting-datetimepicker.js +443 -0
  165. package/lib/layouts/KyInputPicker/setting-input.js +555 -0
  166. package/lib/layouts/KyInputPicker/setting-inputNumber.js +612 -0
  167. package/lib/layouts/KyInputPicker/setting-monthpicker.js +434 -0
  168. package/lib/layouts/KyInputPicker/setting-multiSelect.js +532 -0
  169. package/lib/layouts/KyInputPicker/setting-nhcascader.js +584 -0
  170. package/lib/layouts/KyInputPicker/setting-old-upload.js +428 -0
  171. package/lib/layouts/KyInputPicker/setting-radio.js +468 -0
  172. package/lib/layouts/KyInputPicker/setting-rangepicker.js +466 -0
  173. package/lib/layouts/KyInputPicker/setting-select.js +534 -0
  174. package/lib/layouts/KyInputPicker/setting-stu-selector.js +507 -0
  175. package/lib/layouts/KyInputPicker/setting-switch.js +274 -0
  176. package/lib/layouts/KyInputPicker/setting-tea-selector.js +507 -0
  177. package/lib/layouts/KyInputPicker/setting-textarea.js +619 -0
  178. package/lib/layouts/KyInputPicker/setting-timepicker.js +437 -0
  179. package/lib/layouts/KyInputPicker/setting-upload.js +766 -0
  180. package/lib/layouts/KyModal/buildTitle.js +81 -0
  181. package/lib/layouts/KyModal/dragM.js +127 -0
  182. package/lib/layouts/KyModal/index.js +321 -0
  183. package/lib/layouts/KyPreview/index.js +219 -0
  184. package/lib/layouts/KyUpload/index.js +1155 -0
  185. package/lib/layouts/LeftMenu/index.js +5 -11
  186. package/lib/layouts/NavigationBar/index.js +4 -10
  187. package/lib/layouts/Top/editPassWord.js +5 -7
  188. package/lib/layouts/Top/index.js +6 -20
  189. package/lib/layouts/TopMenu/index.js +11 -14
  190. package/lib/layouts/layout/index.js +7 -13
  191. package/lib/layouts/{Login → login}/index-pre.js +3 -5
  192. package/lib/layouts/{Login → login}/index.js +6 -8
  193. package/lib/layouts/{Login → login}/login.js +8 -17
  194. package/lib/layouts/mixTop/index.js +13 -28
  195. package/lib/layouts/settingDrawer/index.js +3 -5
  196. package/lib/routes/AuthorizedRoute.js +7 -13
  197. package/lib/utils/NHCore.js +46 -2
  198. package/lib/utils/base64.js +238 -0
  199. package/lib/utils/browserJudge.js +33 -0
  200. package/lib/utils/common.js +18 -20
  201. package/lib/utils/createUuid.js +11 -31
  202. package/lib/utils/device.js +44 -0
  203. package/lib/utils/dynamicLoadCss.js +14 -0
  204. package/lib/utils/dynamicLoadJs.js +21 -0
  205. package/lib/utils/getLoginUser.js +1 -1
  206. package/lib/utils/getSize.js +2 -11
  207. package/lib/utils/getStyle.js +26 -0
  208. package/lib/utils/getSuitHeight.js +49 -0
  209. package/lib/utils/hasAuth.js +11 -0
  210. package/lib/utils/index.js +1 -34
  211. package/lib/utils/loadJS.js +40 -0
  212. package/package.json +1 -1
  213. /package/lib/layouts/{Login → login}/lyPassword.js +0 -0
@@ -0,0 +1,682 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+
7
+ var _card = require("antd-mobile/lib/card");
8
+
9
+ var _card2 = _interopRequireDefault(_card);
10
+
11
+ var _modal = require("antd-mobile/lib/modal");
12
+
13
+ var _modal2 = _interopRequireDefault(_modal);
14
+
15
+ var _picker = require("antd-mobile/lib/picker");
16
+
17
+ var _picker2 = _interopRequireDefault(_picker);
18
+
19
+ var _whiteSpace = require("antd-mobile/lib/white-space");
20
+
21
+ var _whiteSpace2 = _interopRequireDefault(_whiteSpace);
22
+
23
+ var _inputItem = require("antd-mobile/lib/input-item");
24
+
25
+ var _inputItem2 = _interopRequireDefault(_inputItem);
26
+
27
+ var _textareaItem = require("antd-mobile/lib/textarea-item");
28
+
29
+ var _textareaItem2 = _interopRequireDefault(_textareaItem);
30
+
31
+ var _list = require("antd-mobile/lib/list");
32
+
33
+ var _list2 = _interopRequireDefault(_list);
34
+
35
+ var _toast = require("antd-mobile/lib/toast");
36
+
37
+ var _toast2 = _interopRequireDefault(_toast);
38
+
39
+ var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
40
+
41
+ var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }();
42
+
43
+ require("antd-mobile/lib/card/style/css");
44
+
45
+ require("antd-mobile/lib/modal/style/css");
46
+
47
+ require("antd-mobile/lib/picker/style/css");
48
+
49
+ require("antd-mobile/lib/white-space/style/css");
50
+
51
+ require("antd-mobile/lib/input-item/style/css");
52
+
53
+ require("antd-mobile/lib/textarea-item/style/css");
54
+
55
+ require("antd-mobile/lib/list/style/css");
56
+
57
+ require("antd-mobile/lib/toast/style/css");
58
+
59
+ var _react = require("react");
60
+
61
+ var _react2 = _interopRequireDefault(_react);
62
+
63
+ var _moment = require("moment");
64
+
65
+ var _moment2 = _interopRequireDefault(_moment);
66
+
67
+ var _NHFetch = require("../../../../../utils/NHFetch");
68
+
69
+ var _NHFetch2 = _interopRequireDefault(_NHFetch);
70
+
71
+ var _index = require("../../../../NHImagePicker/index");
72
+
73
+ var _index2 = _interopRequireDefault(_index);
74
+
75
+ var _rcForm = require("rc-form");
76
+
77
+ var _classnames = require("classnames");
78
+
79
+ var _classnames2 = _interopRequireDefault(_classnames);
80
+
81
+ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
82
+
83
+ function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
84
+
85
+ function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; }
86
+
87
+ function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; }
88
+
89
+ var basicUrl = 'api/sm-punish/';
90
+ var getHashParam = function getHashParam(name) {
91
+ var reg = new RegExp('(^|&)' + name + '=([^&]*)(&|$)'),
92
+ queryString = window.location.hash.split('?')[1] || '',
93
+ result = queryString.match(reg);
94
+ return result ? decodeURIComponent(result[2]) : null;
95
+ };
96
+
97
+ var CfjcEditForm = function (_React$Component) {
98
+ _inherits(CfjcEditForm, _React$Component);
99
+
100
+ function CfjcEditForm(props) {
101
+ _classCallCheck(this, CfjcEditForm);
102
+
103
+ var _this = _possibleConstructorReturn(this, (CfjcEditForm.__proto__ || Object.getPrototypeOf(CfjcEditForm)).call(this, props));
104
+
105
+ _this.componentDidMount = function () {
106
+ var pkid = _this.props.pkid;
107
+
108
+ _this.getStuPunishInfoList();
109
+ _this.getXscfjcxxByPkid(pkid, function (data) {
110
+ if (data) {
111
+ _this.initData(data);
112
+ } else {
113
+ //非审核
114
+ var wjdjid = getHashParam('wjdjid');
115
+ if (wjdjid) {
116
+ (0, _NHFetch2.default)(basicUrl + ("openapi/getXsWjdjByPkid/" + wjdjid), 'GET').then(function (res) {
117
+ if (res && res.code === 200) {
118
+ _this.initData(_extends({}, res.data, { FJID: undefined }));
119
+ } else {
120
+ _toast2.default.fail("获取处分信息失败");
121
+ }
122
+ }).catch(function (e) {
123
+ _toast2.default.fail("获取处分信息失败");
124
+ });
125
+ } else {
126
+ // Toast.info('缺少处分信息')
127
+ _this.setState({ showWjModal: true });
128
+ }
129
+ }
130
+ });
131
+ };
132
+
133
+ _this.initData = function (data) {
134
+ _this.setState({
135
+ cfjgid: data.CFJGID,
136
+ wjlxmc: data.WJLXMC,
137
+ wjsj: data.WJSJSTR || data.WJSJ,
138
+ wjnr: data.WJNR,
139
+ wjss: data.WJSS,
140
+ cflxmc: data.CFMC,
141
+ cfxqmc: data.CFXQMC || data.XQMC,
142
+ cfkssj: data.CFKSSJSTR || data.CFKSSJ,
143
+ cfjssj: data.CFJSSJSTR || data.CFJSSJ,
144
+ cfwh: data.CFWH,
145
+ cfjcwh: data.CFJCWH,
146
+ jcly: data.JCLY,
147
+ fjid: data.FJID || _this.state.fjid
148
+ });
149
+ };
150
+
151
+ _this.onChange = function (seq, value, text) {
152
+ _this.props.onChange && _this.props.onChange(seq, value, text);
153
+ };
154
+
155
+ _this.getXscfjcxxByPkid = function (pkid, callback) {
156
+ (0, _NHFetch2.default)(basicUrl + 'openapi/' + pkid + '/getXscfjcxxByPkid', 'GET').then(function (res) {
157
+ if (res && res.code === 200) {
158
+ callback(res.data);
159
+ } else {
160
+ _toast2.default.fail("获取处分信息失败");
161
+ }
162
+ });
163
+ };
164
+
165
+ _this.requiredParams = function (required, id) {
166
+ var getFieldError = _this.props.form.getFieldError;
167
+
168
+ return {
169
+ error: getFieldError(id) !== undefined
170
+ };
171
+ };
172
+
173
+ _this.getStuPunishInfoList = function () {
174
+ (0, _NHFetch2.default)(basicUrl + 'openapi/getStuPunishInfoList', "GET").then(function (res) {
175
+ if (res && res.data) {
176
+ var cfxxList = [];
177
+ res.data.map(function (item, index) {
178
+ var cfxxMap = {};
179
+ cfxxMap.label = item.LABEL;
180
+ cfxxMap.value = item.VALUE;
181
+ cfxxList.push(cfxxMap);
182
+ });
183
+ _this.setState({ cfxxList: cfxxList });
184
+ } else {
185
+ _toast2.default.fail("该学生暂无违纪信息!");
186
+ }
187
+ });
188
+ };
189
+
190
+ _this.getDataList = function (fieldMap) {
191
+ var _this$props$form = _this.props.form,
192
+ getFieldProps = _this$props$form.getFieldProps,
193
+ getFieldError = _this$props$form.getFieldError;
194
+ var _this$state = _this.state,
195
+ wjlxmc = _this$state.wjlxmc,
196
+ wjsj = _this$state.wjsj,
197
+ wjnr = _this$state.wjnr,
198
+ wjss = _this$state.wjss,
199
+ cflxmc = _this$state.cflxmc,
200
+ cfxqmc = _this$state.cfxqmc,
201
+ cfkssj = _this$state.cfkssj,
202
+ cfjssj = _this$state.cfjssj,
203
+ cfjcwh = _this$state.cfjcwh,
204
+ jcly = _this$state.jcly,
205
+ cfjgid = _this$state.cfjgid,
206
+ fjid = _this$state.fjid;
207
+
208
+ var fieldMapList = [];
209
+ //违纪类型,只展示,不能编辑,因此不做处理
210
+ if (fieldMap.WJLXMC && fieldMap.WJLXMC.sfxs === '1') {
211
+ var required = fieldMap.WJLXMC.sfbt === "1" ? true : false;
212
+ var editable = fieldMap.WJLXMC.sfbj === "1" ? true : false;
213
+ fieldMapList.push({
214
+ id: 'wjlxmc',
215
+ title: '违纪类型',
216
+ isUpload: false,
217
+ text: wjlxmc,
218
+ required: required,
219
+ render: function render() {
220
+ getFieldProps('cfjgid', {
221
+ initialValue: cfjgid
222
+ });
223
+ return _react2.default.createElement(
224
+ "div",
225
+ { className: (0, _classnames2.default)({ 'nh-inputrender': editable, 'nh-inputrender-disabled': !editable }) },
226
+ _react2.default.createElement(
227
+ _list2.default.Item,
228
+ {
229
+ extra: wjlxmc
230
+ },
231
+ "\u8FDD\u7EAA\u7C7B\u578B"
232
+ )
233
+ );
234
+ }
235
+ });
236
+ }
237
+
238
+ //违纪时间
239
+ if (fieldMap.WJSJ && fieldMap.WJSJ.sfxs === '1') {
240
+ var _required = fieldMap.WJSJ.sfbt === "1" ? true : false;
241
+ var _editable = fieldMap.WJSJ.sfbj === "1" ? true : false;
242
+ fieldMapList.push({
243
+ id: 'wjsj',
244
+ title: '违纪时间',
245
+ isUpload: false,
246
+ text: wjsj,
247
+ required: _required,
248
+ render: function render() {
249
+ getFieldProps('wjsj', {
250
+ initialValue: wjsj ? (0, _moment2.default)(wjsj, "YYYY-MM-DD") : null
251
+ });
252
+ return _react2.default.createElement(
253
+ "div",
254
+ { className: (0, _classnames2.default)({ 'nh-inputrender': _editable, 'nh-inputrender-disabled': !_editable }) },
255
+ _react2.default.createElement(
256
+ _list2.default.Item,
257
+ {
258
+ extra: wjsj
259
+ },
260
+ "\u8FDD\u7EAA\u65F6\u95F4"
261
+ )
262
+ );
263
+ }
264
+ });
265
+ }
266
+
267
+ //处分类型
268
+ if (fieldMap.CFLXMC && fieldMap.CFLXMC.sfxs === '1') {
269
+ var _required2 = fieldMap.CFLXMC.sfbt === "1" ? true : false;
270
+ var _editable2 = fieldMap.CFLXMC.sfbj === "1" ? true : false;
271
+ fieldMapList.push({
272
+ id: 'cflxmc',
273
+ title: '处分类型',
274
+ isUpload: false,
275
+ text: cflxmc,
276
+ required: _required2,
277
+ render: function render() {
278
+ getFieldProps('cflxmc', {
279
+ initialValue: cflxmc
280
+ });
281
+ return _react2.default.createElement(
282
+ "div",
283
+ { className: (0, _classnames2.default)({ 'nh-inputrender': _editable2, 'nh-inputrender-disabled': !_editable2 }) },
284
+ _react2.default.createElement(
285
+ _list2.default.Item,
286
+ {
287
+ extra: cflxmc
288
+ },
289
+ "\u5904\u5206\u7C7B\u578B"
290
+ )
291
+ );
292
+ }
293
+ });
294
+ }
295
+
296
+ //处分学期
297
+ if (fieldMap.CFXQMC && fieldMap.CFXQMC.sfxs === '1') {
298
+ var _required3 = fieldMap.CFXQMC.sfbt === "1" ? true : false;
299
+ var _editable3 = fieldMap.CFXQMC.sfbj === "1" ? true : false;
300
+ fieldMapList.push({
301
+ id: 'cfxqmc',
302
+ title: '处分学期',
303
+ isUpload: false,
304
+ text: cfxqmc,
305
+ required: _required3,
306
+ render: function render() {
307
+ getFieldProps('cfxqmc', {
308
+ initialValue: cfxqmc
309
+ });
310
+ return _react2.default.createElement(
311
+ "div",
312
+ { className: (0, _classnames2.default)({ 'nh-inputrender': _editable3, 'nh-inputrender-disabled': !_editable3 }) },
313
+ _react2.default.createElement(
314
+ _list2.default.Item,
315
+ {
316
+ multipleLine: true
317
+ },
318
+ "\u5904\u5206\u5B66\u671F",
319
+ _react2.default.createElement(
320
+ _list2.default.Item.Brief,
321
+ null,
322
+ cfxqmc
323
+ )
324
+ )
325
+ );
326
+ }
327
+ });
328
+ }
329
+
330
+ //处分开始时间
331
+ if (fieldMap.CFKSSJ && fieldMap.CFKSSJ.sfxs === '1') {
332
+ var _required4 = fieldMap.CFKSSJ.sfbt === "1" ? true : false;
333
+ var _editable4 = fieldMap.CFKSSJ.sfbj === "1" ? true : false;
334
+ fieldMapList.push({
335
+ id: 'cfkssj',
336
+ title: '处分开始时间',
337
+ isUpload: false,
338
+ text: cfkssj,
339
+ required: _required4,
340
+ render: function render() {
341
+ getFieldProps('cfkssj', {
342
+ initialValue: cfkssj
343
+ });
344
+ return _react2.default.createElement(
345
+ "div",
346
+ { className: (0, _classnames2.default)({ 'nh-inputrender': _editable4, 'nh-inputrender-disabled': !_editable4 }) },
347
+ _react2.default.createElement(
348
+ _list2.default.Item,
349
+ {
350
+ extra: cfkssj
351
+ },
352
+ "\u5904\u5206\u5F00\u59CB\u65F6\u95F4"
353
+ )
354
+ );
355
+ }
356
+ });
357
+ }
358
+
359
+ //处分结束时间
360
+ if (fieldMap.CFJSSJ && fieldMap.CFJSSJ.sfxs === '1') {
361
+ var _required5 = fieldMap.CFJSSJ.sfbt === "1" ? true : false;
362
+ var _editable5 = fieldMap.CFJSSJ.sfbj === "1" ? true : false;
363
+ fieldMapList.push({
364
+ id: 'cfjssj',
365
+ title: '处分结束时间',
366
+ isUpload: false,
367
+ text: cfjssj,
368
+ required: _required5,
369
+ render: function render() {
370
+ getFieldProps('cfjssj', {
371
+ initialValue: cfjssj
372
+ });
373
+ return _react2.default.createElement(
374
+ "div",
375
+ { className: (0, _classnames2.default)({ 'nh-inputrender': _editable5, 'nh-inputrender-disabled': !_editable5 }) },
376
+ _react2.default.createElement(
377
+ _list2.default.Item,
378
+ {
379
+ extra: cfjssj
380
+ },
381
+ "\u5904\u5206\u7ED3\u675F\u65F6\u95F4"
382
+ )
383
+ );
384
+ }
385
+ });
386
+ }
387
+
388
+ //违纪内容
389
+ if (fieldMap.WJNR && fieldMap.WJNR.sfxs === '1') {
390
+ var _required6 = fieldMap.WJNR.sfbt === "1" ? true : false;
391
+ fieldMapList.push({
392
+ id: 'wjnr',
393
+ title: '违纪内容',
394
+ isUpload: false,
395
+ text: wjnr,
396
+ required: _required6,
397
+ render: function render() {
398
+ getFieldProps('wjnr', {
399
+ initialValue: wjnr
400
+ });
401
+ return _react2.default.createElement(_textareaItem2.default, {
402
+ title: "\u8FDD\u7EAA\u5185\u5BB9",
403
+ rows: 3,
404
+ disabled: true,
405
+ value: wjnr
406
+ });
407
+ }
408
+ });
409
+ }
410
+
411
+ //违纪事实
412
+ if (fieldMap.WJSS && fieldMap.WJSS.sfxs === '1') {
413
+ var _required7 = fieldMap.WJSS.sfbt === "1" ? true : false;
414
+ fieldMapList.push({
415
+ id: 'wjss',
416
+ title: '违纪事实',
417
+ isUpload: false,
418
+ text: wjss,
419
+ required: _required7,
420
+ render: function render() {
421
+ getFieldProps('wjss', {
422
+ initialValue: wjss
423
+ });
424
+ return _react2.default.createElement(_textareaItem2.default, {
425
+ title: fieldMap.WJSS.title,
426
+ rows: 3,
427
+ disabled: true,
428
+ value: wjss
429
+ });
430
+ }
431
+ });
432
+ }
433
+
434
+ //解除理由
435
+ if (fieldMap.JCLY && fieldMap.JCLY.sfxs === '1') {
436
+ var _required8 = fieldMap.JCLY.sfbt === "1" ? true : false;
437
+ var _editable6 = fieldMap.JCLY.sfbj === "1" ? true : false;
438
+ fieldMapList.push({
439
+ id: 'jcly',
440
+ title: '解除理由',
441
+ isUpload: false,
442
+ text: jcly,
443
+ required: _required8,
444
+ render: function render() {
445
+ return _react2.default.createElement(_textareaItem2.default, _extends({
446
+ title: "\u89E3\u9664\u7406\u7531",
447
+ placeholder: "\u8BF7\u8F93\u5165",
448
+ rows: 4,
449
+ count: 120,
450
+ editable: _editable6,
451
+ disabled: !_editable6
452
+ }, _this.requiredParams(_required8, 'jcly'), getFieldProps('jcly', {
453
+ initialValue: jcly,
454
+ rules: [{ required: _required8, message: '请输入解除理由' }]
455
+ })));
456
+ }
457
+ });
458
+ }
459
+
460
+ //处分解除文号
461
+ if (fieldMap.CFJCWH && fieldMap.CFJCWH.sfxs === '1') {
462
+ //处分文号
463
+ var _required9 = fieldMap.CFJCWH.sfbt === "1" ? true : false;
464
+ var _editable7 = fieldMap.CFJCWH.sfbj === "1" ? true : false;
465
+
466
+ fieldMapList.push({
467
+ id: 'cfjcwh',
468
+ title: '解除文号',
469
+ isUpload: false,
470
+ text: cfjcwh,
471
+ required: _required9,
472
+ render: function render() {
473
+ return _react2.default.createElement(
474
+ _inputItem2.default,
475
+ _extends({
476
+ placeholder: "\u8BF7\u8F93\u5165",
477
+ className: "nh-input-item",
478
+ editable: _editable7,
479
+ count: 15,
480
+ disabled: !_editable7
481
+ }, _this.requiredParams(_required9, 'cfjcwh'), getFieldProps('cfjcwh', {
482
+ initialValue: cfjcwh,
483
+ rules: [{ required: _required9, message: '请输入解除文号' }]
484
+ })),
485
+ "\u89E3\u9664\u6587\u53F7"
486
+ );
487
+ }
488
+ });
489
+ }
490
+ if (fieldMap.FJID && fieldMap.FJID.sfxs === '1') {
491
+ var _required10 = fieldMap.FJID.sfbt === "1" ? true : false;
492
+ var _editable8 = fieldMap.FJID.sfbj === "1" ? true : false;
493
+ fieldMapList.push({
494
+ id: 'fjid',
495
+ title: '附件上传',
496
+ text: fjid,
497
+ required: _required10,
498
+ isUpload: true,
499
+ render: function render() {
500
+ return _react2.default.createElement(
501
+ _list2.default.Item,
502
+ _this.requiredParams(_required10, 'fjid'),
503
+ _react2.default.createElement(
504
+ "label",
505
+ { className: (0, _classnames2.default)({ 'nh-dynamic-form-disabled': !_editable8 }) },
506
+ "\u9644\u4EF6\u4E0A\u4F20"
507
+ ),
508
+ _react2.default.createElement(_index2.default, _extends({
509
+ serviceMark: 'sm-punish',
510
+ moduleName: '违纪处分-处分解除',
511
+ isEdit: _this.props.isEdit && _editable8,
512
+ numberOfLimit: 10,
513
+ numberOfSize: 5
514
+ }, getFieldProps('fjid', {
515
+ initialValue: fjid,
516
+ rules: [{ required: _required10, message: '请上传附件' }]
517
+ })))
518
+ );
519
+ },
520
+ renderView: function renderView() {
521
+ return _react2.default.createElement(_index2.default, {
522
+ serviceMark: 'sm-punish',
523
+ moduleName: '违纪处分-处分解除',
524
+ isEdit: false,
525
+ value: fjid
526
+ });
527
+ }
528
+ });
529
+ }
530
+ return fieldMapList;
531
+ };
532
+
533
+ _this.cfxxListChange = function (v) {
534
+ console.log(v);
535
+ if (v) {
536
+ (0, _NHFetch2.default)(basicUrl + "openapi/getXsWjdjByPkid/" + v, 'GET').then(function (res) {
537
+ if (res && res.code === 200) {
538
+ _this.setState({ showWjModal: false }, function () {
539
+ _this.initData(_extends({}, res.data, { FJID: undefined }));
540
+ });
541
+ } else {
542
+ _toast2.default.fail("获取处分信息失败");
543
+ }
544
+ }).catch(function (e) {
545
+ _toast2.default.fail("获取处分信息失败");
546
+ });
547
+ }
548
+ };
549
+
550
+ _this.state = {
551
+ wjlxmc: '', //违纪类型名称
552
+ wjsj: '', //违纪时间
553
+ wjnr: '', //违纪内容
554
+ wjss: '', //违纪事实
555
+ cflxmc: '', //处分类型
556
+ cfxqmc: '', //处分学期
557
+ cfkssj: '', //处分开始时间
558
+ cfjssj: '', //处分结束时间
559
+ cfwh: '', //处分文号
560
+ cfjcwh: '', //处分解除文号
561
+ jcly: '', //申请理由
562
+ cfjgid: '', //处分结果ID
563
+ fjid: undefined,
564
+ cfxxList: [],
565
+ showWjModal: false
566
+ };
567
+ return _this;
568
+ }
569
+
570
+ //查询学生处分解除信息
571
+
572
+
573
+ _createClass(CfjcEditForm, [{
574
+ key: "render",
575
+ value: function render() {
576
+ var _props = this.props,
577
+ form = _props.form,
578
+ isEdit = _props.isEdit,
579
+ fieldMap = _props.fieldMap,
580
+ title = _props.title;
581
+ var getFieldProps = this.props.form.getFieldProps;
582
+ var cfxxList = this.state.cfxxList;
583
+
584
+ var dataList = this.getDataList(fieldMap);
585
+ if (isEdit) {
586
+ return _react2.default.createElement(
587
+ "form",
588
+ null,
589
+ _react2.default.createElement(
590
+ _list2.default,
591
+ { renderHeader: function renderHeader() {
592
+ return title;
593
+ } },
594
+ dataList.map(function (item, index) {
595
+ return _react2.default.createElement(
596
+ "div",
597
+ { key: index, className: (0, _classnames2.default)('nh-dynamic-list-item', { 'nh-dynamic-required': item.required }) },
598
+ item.render !== undefined ? item.render() : null
599
+ );
600
+ })
601
+ ),
602
+ _react2.default.createElement(_whiteSpace2.default, { size: "lg" }),
603
+ _react2.default.createElement(
604
+ _modal2.default,
605
+ {
606
+ visible: this.state.showWjModal,
607
+ closable: false,
608
+ popup: true,
609
+ title: "违纪情况",
610
+ maskClosable: false
611
+ },
612
+ _react2.default.createElement(
613
+ _picker2.default,
614
+ _extends({ data: cfxxList, cols: 1 }, getFieldProps('cfxxId', { onChange: this.cfxxListChange }), { className: "forss" }),
615
+ _react2.default.createElement(
616
+ _list2.default.Item,
617
+ { arrow: "horizontal" },
618
+ _react2.default.createElement(
619
+ "font",
620
+ { color: "red" },
621
+ "*"
622
+ ),
623
+ "\u8FDD\u7EAA\u4FE1\u606F"
624
+ )
625
+ )
626
+ )
627
+ );
628
+ }
629
+ return _react2.default.createElement(
630
+ "div",
631
+ null,
632
+ _react2.default.createElement(
633
+ _card2.default,
634
+ { full: true },
635
+ _react2.default.createElement(_card2.default.Header, {
636
+ title: _react2.default.createElement(
637
+ "div",
638
+ { style: { borderLeft: '3px solid #1890ff', paddingLeft: '10px' } },
639
+ title
640
+ )
641
+ }),
642
+ _react2.default.createElement(
643
+ _card2.default.Body,
644
+ null,
645
+ dataList.map(function (item, index) {
646
+ if (item.isUpload) {
647
+ return _react2.default.createElement(
648
+ "div",
649
+ { key: index },
650
+ _react2.default.createElement(
651
+ "font",
652
+ { color: "grey" },
653
+ item.title,
654
+ "\uFF1A "
655
+ ),
656
+ item.renderView()
657
+ );
658
+ }
659
+ return _react2.default.createElement(
660
+ "div",
661
+ { key: index },
662
+ _react2.default.createElement(
663
+ "font",
664
+ { color: "grey" },
665
+ item.title,
666
+ "\uFF1A "
667
+ ),
668
+ item.text,
669
+ _react2.default.createElement("br", null)
670
+ );
671
+ })
672
+ )
673
+ ),
674
+ _react2.default.createElement(_whiteSpace2.default, { size: "lg" })
675
+ );
676
+ }
677
+ }]);
678
+
679
+ return CfjcEditForm;
680
+ }(_react2.default.Component);
681
+
682
+ exports.default = (0, _rcForm.createForm)()(CfjcEditForm);