dlt-for-react 1.1.3 → 1.1.4

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 (187) hide show
  1. package/README.md +4 -0
  2. package/lib/index.js +7 -1
  3. package/lib/layouts/Top/index.js +1 -1
  4. package/lib/layouts/layout/index.js +77 -31
  5. package/lib/layouts/mixTop/index.js +3 -3
  6. package/lib/utils/createUuid.js +31 -11
  7. package/lib/utils/getLoginUser.js +1 -1
  8. package/lib/utils/getSize.js +11 -2
  9. package/lib/utils/index.js +35 -2
  10. package/package.json +1 -1
  11. package/lib/components/Button/index.js +0 -79
  12. package/lib/components/NHAuditPanel/config/Axios.js +0 -263
  13. package/lib/components/NHAuditPanel/config/api.js +0 -479
  14. package/lib/components/NHAuditPanel/config/data.js +0 -156
  15. package/lib/components/NHAuditPanel/config/typeMap.js +0 -1234
  16. package/lib/components/NHAuditPanel/config/uiValidate.js +0 -92
  17. package/lib/components/NHAuditPanel/index.js +0 -413
  18. package/lib/components/NHAuditPanel/node.js +0 -619
  19. package/lib/components/NHCascader/index.js +0 -355
  20. package/lib/components/NHCheckboxGroup/index.js +0 -135
  21. package/lib/components/NHDynamicFormShow/baseInfo/index.js +0 -194
  22. package/lib/components/NHDynamicFormShow/custom/index.js +0 -553
  23. package/lib/components/NHDynamicFormShow/customModule/common/CommonMethod.js +0 -43
  24. package/lib/components/NHDynamicFormShow/customModule/czxy/qgzx/EditForm.js +0 -1113
  25. package/lib/components/NHDynamicFormShow/customModule/czxy/qgzx/index.js +0 -263
  26. package/lib/components/NHDynamicFormShow/customModule/czxy/xfjm/EditForm.js +0 -880
  27. package/lib/components/NHDynamicFormShow/customModule/czxy/xfjm/index.js +0 -171
  28. package/lib/components/NHDynamicFormShow/customModule/czxy/zxj/EditForm.js +0 -865
  29. package/lib/components/NHDynamicFormShow/customModule/czxy/zxj/index.js +0 -138
  30. package/lib/components/NHDynamicFormShow/customModule/eszy/zsxxhd/EditForm.js +0 -571
  31. package/lib/components/NHDynamicFormShow/customModule/eszy/zsxxhd/index.js +0 -147
  32. package/lib/components/NHDynamicFormShow/customModule/eszy/zybjtz/EditForm.js +0 -474
  33. package/lib/components/NHDynamicFormShow/customModule/eszy/zybjtz/index.js +0 -139
  34. package/lib/components/NHDynamicFormShow/customModule/gnyxy/cqzg/EditForm.js +0 -506
  35. package/lib/components/NHDynamicFormShow/customModule/gnyxy/cqzg/index.js +0 -143
  36. package/lib/components/NHDynamicFormShow/customModule/gnyxy/gwsb/EditForm.js +0 -1074
  37. package/lib/components/NHDynamicFormShow/customModule/gnyxy/gwsb/index.js +0 -172
  38. package/lib/components/NHDynamicFormShow/customModule/gnyxy/qjgl/EditForm.js +0 -927
  39. package/lib/components/NHDynamicFormShow/customModule/gnyxy/qjgl/index.js +0 -195
  40. package/lib/components/NHDynamicFormShow/customModule/gnyxy/sxsqj/EditForm.js +0 -1064
  41. package/lib/components/NHDynamicFormShow/customModule/gnyxy/sxsqj/index.js +0 -183
  42. package/lib/components/NHDynamicFormShow/customModule/hblgxy/jxj/EditForm.js +0 -763
  43. package/lib/components/NHDynamicFormShow/customModule/hblgxy/jxj/index.js +0 -137
  44. package/lib/components/NHDynamicFormShow/customModule/hblgxy/lzjxj/EditForm.js +0 -819
  45. package/lib/components/NHDynamicFormShow/customModule/hblgxy/lzjxj/index.js +0 -137
  46. package/lib/components/NHDynamicFormShow/customModule/hblgxy/qgzx/EditForm.js +0 -700
  47. package/lib/components/NHDynamicFormShow/customModule/hblgxy/qgzx/index.js +0 -162
  48. package/lib/components/NHDynamicFormShow/customModule/hblgxy/xsqj/EditForm.js +0 -743
  49. package/lib/components/NHDynamicFormShow/customModule/hblgxy/xsqj/index.js +0 -177
  50. package/lib/components/NHDynamicFormShow/customModule/hblgxy/zxj/EditForm.js +0 -848
  51. package/lib/components/NHDynamicFormShow/customModule/hblgxy/zxj/index.js +0 -138
  52. package/lib/components/NHDynamicFormShow/customModule/hljwgy/qjgl/EditForm.js +0 -777
  53. package/lib/components/NHDynamicFormShow/customModule/hljwgy/qjgl/index.js +0 -161
  54. package/lib/components/NHDynamicFormShow/customModule/hljwgy/xjgl/EditForm.js +0 -706
  55. package/lib/components/NHDynamicFormShow/customModule/hljwgy/xjgl/index.js +0 -130
  56. package/lib/components/NHDynamicFormShow/customModule/jhysxy/cfjcsq/cfjcEditForm.js +0 -413
  57. package/lib/components/NHDynamicFormShow/customModule/jhysxy/cfjcsq/index.js +0 -135
  58. package/lib/components/NHDynamicFormShow/customModule/jhysxy/xsqj/EditForm.js +0 -1013
  59. package/lib/components/NHDynamicFormShow/customModule/jhysxy/xsqj/index.js +0 -175
  60. package/lib/components/NHDynamicFormShow/customModule/jjrlx/EditForm.js +0 -1345
  61. package/lib/components/NHDynamicFormShow/customModule/jjrlx/index.js +0 -274
  62. package/lib/components/NHDynamicFormShow/customModule/jxj/EditForm.js +0 -669
  63. package/lib/components/NHDynamicFormShow/customModule/jxj/index.js +0 -134
  64. package/lib/components/NHDynamicFormShow/customModule/jxsl/fqkns/EditForm.js +0 -378
  65. package/lib/components/NHDynamicFormShow/customModule/jxsl/fqkns/index.js +0 -120
  66. package/lib/components/NHDynamicFormShow/customModule/jxsl/xwryfjjd/EditForm.js +0 -638
  67. package/lib/components/NHDynamicFormShow/customModule/jxsl/xwryfjjd/index.js +0 -133
  68. package/lib/components/NHDynamicFormShow/customModule/qgzx/EditForm.js +0 -965
  69. package/lib/components/NHDynamicFormShow/customModule/qgzx/index.js +0 -237
  70. package/lib/components/NHDynamicFormShow/customModule/qjgl/EditForm.js +0 -823
  71. package/lib/components/NHDynamicFormShow/customModule/qjgl/index.js +0 -188
  72. package/lib/components/NHDynamicFormShow/customModule/rcgl/jqlssq/EditForm.js +0 -401
  73. package/lib/components/NHDynamicFormShow/customModule/rcgl/jqlssq/index.js +0 -472
  74. package/lib/components/NHDynamicFormShow/customModule/rcgl/tssq/EditForm.js +0 -304
  75. package/lib/components/NHDynamicFormShow/customModule/rcgl/tssq/NHCascader/index.js +0 -375
  76. package/lib/components/NHDynamicFormShow/customModule/rcgl/tssq/NHInputPicker/RadioGroup.js +0 -118
  77. package/lib/components/NHDynamicFormShow/customModule/rcgl/tssq/NHInputPicker/index.js +0 -62
  78. package/lib/components/NHDynamicFormShow/customModule/rcgl/tssq/NHInputPicker/input-const.js +0 -55
  79. package/lib/components/NHDynamicFormShow/customModule/rcgl/tssq/NHInputPicker/render.js +0 -1238
  80. package/lib/components/NHDynamicFormShow/customModule/rcgl/tssq/index.js +0 -375
  81. package/lib/components/NHDynamicFormShow/customModule/rych/collective/EditForm.js +0 -554
  82. package/lib/components/NHDynamicFormShow/customModule/rych/collective/index.js +0 -130
  83. package/lib/components/NHDynamicFormShow/customModule/rych/personal/EditForm.js +0 -542
  84. package/lib/components/NHDynamicFormShow/customModule/rych/personal/index.js +0 -133
  85. package/lib/components/NHDynamicFormShow/customModule/sxgy/rych/collective/EditForm.js +0 -575
  86. package/lib/components/NHDynamicFormShow/customModule/sxgy/rych/collective/index.js +0 -130
  87. package/lib/components/NHDynamicFormShow/customModule/sxgy/rych/personal/EditForm.js +0 -563
  88. package/lib/components/NHDynamicFormShow/customModule/sxgy/rych/personal/index.js +0 -133
  89. package/lib/components/NHDynamicFormShow/customModule/whcz/qjgl/EditForm.js +0 -745
  90. package/lib/components/NHDynamicFormShow/customModule/whcz/qjgl/index.js +0 -164
  91. package/lib/components/NHDynamicFormShow/customModule/whcz/rccrxy/EditForm.js +0 -587
  92. package/lib/components/NHDynamicFormShow/customModule/whcz/rccrxy/index.js +0 -143
  93. package/lib/components/NHDynamicFormShow/customModule/whdlqjgl/EditForm.js +0 -743
  94. package/lib/components/NHDynamicFormShow/customModule/whdlqjgl/index.js +0 -172
  95. package/lib/components/NHDynamicFormShow/customModule/whgc/jjrlx/EditForm.js +0 -1410
  96. package/lib/components/NHDynamicFormShow/customModule/whgc/jjrlx/index.js +0 -274
  97. package/lib/components/NHDynamicFormShow/customModule/whgc/jxj/EditForm.js +0 -755
  98. package/lib/components/NHDynamicFormShow/customModule/whgc/jxj/index.js +0 -130
  99. package/lib/components/NHDynamicFormShow/customModule/whgc/qjgl/EditForm.js +0 -814
  100. package/lib/components/NHDynamicFormShow/customModule/whgc/qjgl/index.js +0 -188
  101. package/lib/components/NHDynamicFormShow/customModule/whgc/zxj/EditForm.js +0 -769
  102. package/lib/components/NHDynamicFormShow/customModule/whgc/zxj/index.js +0 -130
  103. package/lib/components/NHDynamicFormShow/customModule/whgcrych/EditForm.js +0 -1004
  104. package/lib/components/NHDynamicFormShow/customModule/whgcrych/index.js +0 -126
  105. package/lib/components/NHDynamicFormShow/customModule/whtl/jsrzsq/EditForm.js +0 -503
  106. package/lib/components/NHDynamicFormShow/customModule/whtl/jsrzsq/index.js +0 -149
  107. package/lib/components/NHDynamicFormShow/customModule/whtlyhk/EditForm.js +0 -379
  108. package/lib/components/NHDynamicFormShow/customModule/whtlyhk/index.js +0 -148
  109. package/lib/components/NHDynamicFormShow/customModule/whtlzxj/EditForm.js +0 -748
  110. package/lib/components/NHDynamicFormShow/customModule/whtlzxj/index.js +0 -135
  111. package/lib/components/NHDynamicFormShow/customModule/whtlzy/jxj/EditForm.js +0 -762
  112. package/lib/components/NHDynamicFormShow/customModule/whtlzy/jxj/index.js +0 -134
  113. package/lib/components/NHDynamicFormShow/customModule/wjcf/cfjc/cfjcEditForm.js +0 -682
  114. package/lib/components/NHDynamicFormShow/customModule/wjcf/cfjc/index.js +0 -135
  115. package/lib/components/NHDynamicFormShow/customModule/wjcf/wjsb/index.js +0 -152
  116. package/lib/components/NHDynamicFormShow/customModule/wjcf/wjsb/wjsbEditForm.js +0 -783
  117. package/lib/components/NHDynamicFormShow/customModule/zxj/EditForm.js +0 -764
  118. package/lib/components/NHDynamicFormShow/customModule/zxj/index.js +0 -138
  119. package/lib/components/NHDynamicFormShow/customModule/zzsd/cfjcsq/cfjcEditForm.js +0 -677
  120. package/lib/components/NHDynamicFormShow/customModule/zzsd/cfjcsq/index.js +0 -138
  121. package/lib/components/NHDynamicFormShow/customModule/zzsd/qjgl/EditForm.js +0 -1173
  122. package/lib/components/NHDynamicFormShow/customModule/zzsd/qjgl/index.js +0 -242
  123. package/lib/components/NHDynamicFormShow/customModule/zzsd/rcgl/rcxwgrdj/IndividualRegistForm.js +0 -862
  124. package/lib/components/NHDynamicFormShow/customModule/zzsd/rcgl/rcxwgrdj/IndividualRegistIndex.js +0 -201
  125. package/lib/components/NHDynamicFormShow/customModule/zzsd/stuinfo/messageInfo.js +0 -196
  126. package/lib/components/NHDynamicFormShow/customModule/zzsd/wjsb/index.js +0 -167
  127. package/lib/components/NHDynamicFormShow/customModule/zzsd/wjsb/wjsbEditForm.js +0 -1096
  128. package/lib/components/NHDynamicFormShow/index.js +0 -647
  129. package/lib/components/NHDynamicFormShow/oneOnMany/cardForm/cardItem/index.js +0 -279
  130. package/lib/components/NHDynamicFormShow/oneOnMany/cardForm/index.js +0 -206
  131. package/lib/components/NHDynamicFormShow/oneOnMany/index.js +0 -419
  132. package/lib/components/NHDynamicFormShow/oneOnOne/EditForm.js +0 -401
  133. package/lib/components/NHDynamicFormShow/oneOnOne/index.js +0 -271
  134. package/lib/components/NHImagePicker/index.js +0 -554
  135. package/lib/components/NHInputPicker/RadioGroup.js +0 -118
  136. package/lib/components/NHInputPicker/index.js +0 -62
  137. package/lib/components/NHInputPicker/input-const.js +0 -55
  138. package/lib/components/NHInputPicker/render.js +0 -1271
  139. package/lib/components/NHListView/index.js +0 -374
  140. package/lib/components/NHMapGeolocation/index.js +0 -537
  141. package/lib/components/NHMapGeolocation/initMap/initGdMap.js +0 -104
  142. package/lib/components/NHMapGeolocation/initMap/initTencentMap.js +0 -138
  143. package/lib/components/NHMapGeolocation/style.js +0 -51
  144. package/lib/components/NHMultiSelect/index.js +0 -272
  145. package/lib/components/NHRadioGroup/index.js +0 -118
  146. package/lib/components/NHSelect/index.js +0 -364
  147. package/lib/components/NHTreeMenu/index.js +0 -126
  148. package/lib/components/NHTreeMenu/treeNode.js +0 -164
  149. package/lib/components/StuSelector/index.js +0 -611
  150. package/lib/layouts/KyInputPicker/edit-page.js +0 -585
  151. package/lib/layouts/KyInputPicker/index.js +0 -220
  152. package/lib/layouts/KyInputPicker/input-const.js +0 -134
  153. package/lib/layouts/KyInputPicker/render.js +0 -2477
  154. package/lib/layouts/KyInputPicker/setting-checkbox.js +0 -850
  155. package/lib/layouts/KyInputPicker/setting-datepicker.js +0 -430
  156. package/lib/layouts/KyInputPicker/setting-datetimepicker.js +0 -443
  157. package/lib/layouts/KyInputPicker/setting-input.js +0 -555
  158. package/lib/layouts/KyInputPicker/setting-inputNumber.js +0 -612
  159. package/lib/layouts/KyInputPicker/setting-monthpicker.js +0 -434
  160. package/lib/layouts/KyInputPicker/setting-multiSelect.js +0 -532
  161. package/lib/layouts/KyInputPicker/setting-nhcascader.js +0 -584
  162. package/lib/layouts/KyInputPicker/setting-old-upload.js +0 -428
  163. package/lib/layouts/KyInputPicker/setting-radio.js +0 -468
  164. package/lib/layouts/KyInputPicker/setting-rangepicker.js +0 -466
  165. package/lib/layouts/KyInputPicker/setting-select.js +0 -534
  166. package/lib/layouts/KyInputPicker/setting-stu-selector.js +0 -507
  167. package/lib/layouts/KyInputPicker/setting-switch.js +0 -274
  168. package/lib/layouts/KyInputPicker/setting-tea-selector.js +0 -507
  169. package/lib/layouts/KyInputPicker/setting-textarea.js +0 -619
  170. package/lib/layouts/KyInputPicker/setting-timepicker.js +0 -437
  171. package/lib/layouts/KyInputPicker/setting-upload.js +0 -766
  172. package/lib/layouts/KyModal/buildTitle.js +0 -81
  173. package/lib/layouts/KyModal/dragM.js +0 -127
  174. package/lib/layouts/KyModal/index.js +0 -321
  175. package/lib/layouts/KyPreview/index.js +0 -219
  176. package/lib/layouts/KyUpload/index.js +0 -1155
  177. package/lib/utils/browserJudge.js +0 -33
  178. package/lib/utils/dynamicLoadCss.js +0 -14
  179. package/lib/utils/dynamicLoadJs.js +0 -21
  180. package/lib/utils/getStyle.js +0 -26
  181. package/lib/utils/getSuitHeight.js +0 -49
  182. package/lib/utils/hasAuth.js +0 -11
  183. package/lib/utils/loadJS.js +0 -40
  184. /package/lib/layouts/{login → Login}/index-pre.js +0 -0
  185. /package/lib/layouts/{login → Login}/index.js +0 -0
  186. /package/lib/layouts/{login → Login}/login.js +0 -0
  187. /package/lib/layouts/{login → Login}/lyPassword.js +0 -0
@@ -1,669 +0,0 @@
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 _whiteSpace = require('antd-mobile/lib/white-space');
12
-
13
- var _whiteSpace2 = _interopRequireDefault(_whiteSpace);
14
-
15
- var _textareaItem = require('antd-mobile/lib/textarea-item');
16
-
17
- var _textareaItem2 = _interopRequireDefault(_textareaItem);
18
-
19
- var _stepper = require('antd-mobile/lib/stepper');
20
-
21
- var _stepper2 = _interopRequireDefault(_stepper);
22
-
23
- var _picker = require('antd-mobile/lib/picker');
24
-
25
- var _picker2 = _interopRequireDefault(_picker);
26
-
27
- var _list = require('antd-mobile/lib/list');
28
-
29
- var _list2 = _interopRequireDefault(_list);
30
-
31
- var _inputItem = require('antd-mobile/lib/input-item');
32
-
33
- var _inputItem2 = _interopRequireDefault(_inputItem);
34
-
35
- var _modal = require('antd-mobile/lib/modal');
36
-
37
- var _modal2 = _interopRequireDefault(_modal);
38
-
39
- var _toast = require('antd-mobile/lib/toast');
40
-
41
- var _toast2 = _interopRequireDefault(_toast);
42
-
43
- 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; };
44
-
45
- 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; }; }();
46
-
47
- require('antd-mobile/lib/card/style/css');
48
-
49
- require('antd-mobile/lib/white-space/style/css');
50
-
51
- require('antd-mobile/lib/textarea-item/style/css');
52
-
53
- require('antd-mobile/lib/stepper/style/css');
54
-
55
- require('antd-mobile/lib/picker/style/css');
56
-
57
- require('antd-mobile/lib/list/style/css');
58
-
59
- require('antd-mobile/lib/input-item/style/css');
60
-
61
- require('antd-mobile/lib/modal/style/css');
62
-
63
- require('antd-mobile/lib/toast/style/css');
64
-
65
- var _react = require('react');
66
-
67
- var _react2 = _interopRequireDefault(_react);
68
-
69
- var _NHFetch = require('../../../../utils/NHFetch');
70
-
71
- var _NHFetch2 = _interopRequireDefault(_NHFetch);
72
-
73
- var _index = require('../../../NHImagePicker/index');
74
-
75
- var _index2 = _interopRequireDefault(_index);
76
-
77
- var _rcForm = require('rc-form');
78
-
79
- var _classnames = require('classnames');
80
-
81
- var _classnames2 = _interopRequireDefault(_classnames);
82
-
83
- function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
84
-
85
- function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
86
-
87
- 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; }
88
-
89
- 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; } // import { Form, Input, InputNumber, Select, Switch } from 'antd';
90
-
91
-
92
- var EditInitForm = function (_React$Component) {
93
- _inherits(EditInitForm, _React$Component);
94
-
95
- function EditInitForm(props) {
96
- _classCallCheck(this, EditInitForm);
97
-
98
- var _this = _possibleConstructorReturn(this, (EditInitForm.__proto__ || Object.getPrototypeOf(EditInitForm)).call(this, props));
99
-
100
- _this.componentDidMount = function () {
101
- _this.initJxjForm();
102
- };
103
-
104
- _this.initJxjForm = function () {
105
- var _this$props = _this.props,
106
- objId = _this$props.objId,
107
- pkid = _this$props.pkid,
108
- params = _this$props.params;
109
-
110
- var pcid = params.pcid; //批次ID,也就是任务ID
111
- // pcid = 'bc82f059-e629-4a09-8efc-1ffada5c38c2'
112
- (0, _NHFetch2.default)('api/sm-scholarship/openapi/getDymxByGzfbid/' + pcid, 'GET').then(function (res) {
113
- if (res) {
114
- var mxsm = res.data.length;
115
- if (mxsm === 1) {
116
- //对应的奖项定义是不分等级的
117
- _this.setState({
118
- mxsm: 1,
119
- mxid: res.data[0].MXID,
120
- djmc: res.data[0].DJMC,
121
- sfgdje: res.data[0].SFGDJE,
122
- gdjj: res.data[0].GDJJ,
123
- zdjj: res.data[0].ZDJJ,
124
- zxjj: res.data[0].ZXJJ,
125
- pjzqdm: res.data[0].SJDM,
126
- pjzq: res.data[0].SJMC,
127
- //当奖项定义不是固定金额的时候,申请时je会被作为奖金的初始化值,这个初始化值取奖项定义的最小奖金
128
- je: res.data[0].SFGDJE === '1' ? 0 : res.data[0].ZXJJ
129
-
130
- }, function () {
131
-
132
- //判断是否有资格申请该奖项
133
- var param = {
134
- xsid: objId,
135
- gzfbid: pcid,
136
- mxid: res.data[0].MXID
137
- };
138
- _this.hasQualification(param);
139
- });
140
- } else {
141
- //对应的奖项是分了多个等级的
142
- var djxx = [];
143
- res.data.map(function (v, i) {
144
- djxx.push({ label: v.DJMC, value: v.MXID });
145
- // return <Option value={v.MXID} key={i}>{v.DJMC}</Option>;
146
- });
147
- var mxidxx = res.data.map(function (v, i) {
148
- return v.MXID;
149
- });
150
- var gdjjxx = res.data.map(function (v, i) {
151
- return v.GDJJ;
152
- });
153
- _this.setState({
154
- mxsm: mxsm,
155
- djxx: djxx,
156
- pjzqdm: res.data[0].SJDM,
157
- pjzq: res.data[0].SJMC,
158
- mxidxx: mxidxx,
159
- gdjjxx: gdjjxx
160
- });
161
- }
162
-
163
- //通过主键ID获取获奖名单表对应的数据
164
- _this.getData(pkid);
165
- }
166
- });
167
- };
168
-
169
- _this.getData = function (pkid) {
170
- //通过PKID去查询是否有申请数据,有说明是审核
171
- (0, _NHFetch2.default)('api/sm-scholarship/openapi/getXshjmdByPkid/' + pkid, 'GET').then(function (res) {
172
- if (res && res.code === 200) {
173
- if (res.data != null) {
174
- _this.setState({
175
-
176
- mxid: res.data.MXID,
177
- pjzq: res.data.SJMC,
178
- pjzqdm: res.data.SJDM,
179
- //对于不固定金额的情况,审核时页面的金额应该是从申请数据里拿了,所以je的值要重新覆盖下
180
- je: res.data.JE,
181
- sqly: res.data.SQLY,
182
- fjid: res.data.FJID,
183
- djmc: res.data.DJMC,
184
- sfgdje: res.data.SFGDJE,
185
- gdjj: res.data.GDJJ,
186
- zdjj: res.data.ZDJJ,
187
- zxjj: res.data.ZXJJ,
188
- //只有当奖项是分等级的时候,gdjjBydj这个值才会用到。所以直接给它赋值res.data.JE
189
- gdjjBydj: res.data.JE
190
- });
191
- }
192
- } else {
193
- _toast2.default.fail("调用接口失败");
194
- }
195
- });
196
- };
197
-
198
- _this.hasQualification = function (param) {
199
- _this.props.setSubmitBtnDisabled && _this.props.setSubmitBtnDisabled(true); //默认办理按钮不可用
200
- (0, _NHFetch2.default)('api/sm-scholarship/openapi/hasQualification', 'POST', param).then(function (res) {
201
- if (res && res.code === 200) {
202
- // const key = `open${Date.now()}`;
203
- // const btn = (<Button type="primary" size="small" onClick={() => notification.close(key)}>确定</Button>)
204
-
205
- if (!res.data.ZGMDID) {
206
- //资格名单表查不到记录,调用资格鉴定接口
207
- var zgid = res.data.ZGID2 ? res.data.ZGID2 : res.data.ZGID1;
208
- (0, _NHFetch2.default)("api/sm-qualification/openapi/qualifications/checkOne?zgid=" + zgid + "&id=" + param.xsid + "&t=" + new Date().getTime(), "GET").then(function (res) {
209
- if (res && res.code === 200) {
210
-
211
- if (res.data.zt === '0' || res.data.zt === 0) {
212
- var bfhtjs = res.data.bfhtj.split(";");
213
- var bfhtj = bfhtjs.map(function (item, index) {
214
- return _react2.default.createElement(
215
- 'span',
216
- { key: index + 1 },
217
- index + 1,
218
- '\u3001',
219
- item,
220
- _react2.default.createElement('br', null)
221
- );
222
- });
223
-
224
- var msgTip = '';
225
- if (bfhtjs && bfhtjs.length > 0) {
226
- for (var i = 0; i < bfhtjs.length; i++) {
227
- var currentTip = i + 1 + ' ' + bfhtjs[i] + ' ';
228
- msgTip += currentTip;
229
- }
230
- }
231
-
232
- var modelMessage = "您由于不满足以下条件,所以不能执行申请操作:" + msgTip;
233
- _modal2.default.alert('提示', modelMessage);
234
- } else {
235
- _this.props.setSubmitBtnDisabled && _this.props.setSubmitBtnDisabled(false); //CheackOne通过后开启办理按钮
236
- }
237
- } else {
238
- _toast2.default.fail("调用接口失败");
239
- }
240
- });
241
- } else {
242
- //表里有数据,看sfyx字段的状态
243
-
244
- if (res.data.SFYX === "0" || res.data.SFYX === 0) {
245
- var modelMessage = "您由于不满足以下条件,所以不能执行申请操作:" + res.data.SFYXLY;
246
- _modal2.default.alert('提示', modelMessage);
247
- } else {
248
- _this.props.setSubmitBtnDisabled && _this.props.setSubmitBtnDisabled(false); //能办理的话开启办理按钮
249
- }
250
- }
251
- } else {
252
- _toast2.default.fail("调用接口失败");
253
- }
254
- });
255
- };
256
-
257
- _this.changeDj = function (v) {
258
- var _this$props2 = _this.props,
259
- objId = _this$props2.objId,
260
- params = _this$props2.params;
261
- var _this$state = _this.state,
262
- mxidxx = _this$state.mxidxx,
263
- gdjjxx = _this$state.gdjjxx;
264
-
265
- if (!v && v.length < 1) return;
266
- var index = mxidxx.findIndex(function (item) {
267
- return item === v[0];
268
- });
269
- _this.setState({
270
- gdjjBydj: gdjjxx[index]
271
- }, function () {
272
- //验证是否有资格申请
273
- var param = {
274
- xsid: objId,
275
- gzfbid: params.pcid,
276
- mxid: v[0]
277
- };
278
- _this.props.form.setFieldsValue({ je: gdjjxx[index] });
279
- _this.hasQualification(param);
280
- });
281
- };
282
-
283
- _this.onChangeStepper = function (val) {
284
- _this.setState({ je: val });
285
- };
286
-
287
- _this.requiredParams = function (required, id) {
288
- var getFieldError = _this.props.form.getFieldError;
289
-
290
- return {
291
- error: getFieldError(id) !== undefined
292
- };
293
- };
294
-
295
- _this.getDataList = function (fieldMap) {
296
- // const { getFieldDecorator } = this.props.form;
297
- var _this$props$form = _this.props.form,
298
- getFieldProps = _this$props$form.getFieldProps,
299
- getFieldError = _this$props$form.getFieldError;
300
- var _this$state2 = _this.state,
301
- mxsm = _this$state2.mxsm,
302
- mxid = _this$state2.mxid,
303
- djmc = _this$state2.djmc,
304
- djxx = _this$state2.djxx,
305
- sfgdje = _this$state2.sfgdje,
306
- gdjj = _this$state2.gdjj,
307
- zdjj = _this$state2.zdjj,
308
- zxjj = _this$state2.zxjj,
309
- gdjjBydj = _this$state2.gdjjBydj,
310
- pjzq = _this$state2.pjzq,
311
- pjzqdm = _this$state2.pjzqdm,
312
- je = _this$state2.je,
313
- sqly = _this$state2.sqly,
314
- fjid = _this$state2.fjid;
315
-
316
- var dataList = [];
317
-
318
- if (fieldMap.DJMC && fieldMap.DJMC.sfxs === '1') {
319
- var required = fieldMap.DJMC.sfbt === "1" ? true : false;
320
- var editable = fieldMap.DJMC.sfbj === "1" ? true : false;
321
- if (mxsm === 1) {
322
- //没有分等级的,奖项名称始终显示
323
- dataList.push({
324
- title: fieldMap.DJMC.title,
325
- text: djmc,
326
- required: required,
327
- render: function render() {
328
- getFieldProps('mxid', {
329
- initialValue: mxid
330
- });
331
- return _react2.default.createElement(
332
- _inputItem2.default,
333
- {
334
- className: 'nh-input-item',
335
- placeholder: '\u8BF7\u8F93\u5165',
336
- value: djmc,
337
- editable: false,
338
- disabled: !editable
339
- },
340
- fieldMap.DJMC.title
341
- );
342
- }
343
- });
344
- } else {
345
- //分等级,申请的时候奖项名称始终是一个下拉框
346
- dataList.push({
347
- // id: 'dymx',
348
- title: fieldMap.DJMC.title,
349
- required: required,
350
- text: djmc,
351
- render: function render() {
352
- return _react2.default.createElement(
353
- 'div',
354
- {
355
- className: (0, _classnames2.default)({ 'nh-inputrender': editable, 'nh-inputrender-disabled': !editable })
356
- },
357
- _react2.default.createElement(
358
- _picker2.default,
359
- _extends({
360
- data: djxx,
361
- cols: 1,
362
- className: 'forss',
363
- disabled: !editable
364
- }, getFieldProps('mxid', {
365
- initialValue: typeof mxid === 'string' ? [mxid] : mxid,
366
- rules: [{ required: required, message: '\u8BF7\u8F93\u5165' + fieldMap.DJMC.title }],
367
- onChange: _this.changeDj
368
- })),
369
- _react2.default.createElement(
370
- _list2.default.Item,
371
- _extends({ arrow: 'horizontal' }, _this.requiredParams(required, 'mxid')),
372
- fieldMap.DJMC.title
373
- )
374
- )
375
- );
376
- }
377
- });
378
- }
379
- }
380
-
381
- if (fieldMap.JE && fieldMap.JE.sfxs === '1') {
382
- var _required = fieldMap.JE.sfbt === "1" ? true : false;
383
- var _editable = fieldMap.JE.sfbj === "1" ? true : false;
384
- if (mxsm === 1) {
385
- //没有分等级的
386
- if (sfgdje === '1') {
387
- //固定奖金
388
- dataList.push({
389
- title: fieldMap.JE.title,
390
- text: gdjj,
391
- required: _required,
392
- render: function render() {
393
- return _react2.default.createElement(
394
- _inputItem2.default,
395
- _extends({
396
- className: 'nh-input-item',
397
- placeholder: '\u8BF7\u8F93\u5165',
398
- editable: false,
399
- disabled: !_editable
400
- }, _this.requiredParams(_required, 'je'), getFieldProps('je', {
401
- initialValue: gdjj,
402
- rules: [{ required: _required, message: '\u8BF7\u8F93\u5165' + fieldMap.JE.title }]
403
- })),
404
- fieldMap.JE.title
405
- );
406
- }
407
- });
408
- } else {
409
- //没有固定金额
410
- dataList.push({
411
- title: fieldMap.JE.title,
412
- required: _required,
413
- text: je,
414
- render: function render() {
415
- return _react2.default.createElement(
416
- _list2.default.Item,
417
- { extra: _react2.default.createElement(_stepper2.default, _extends({
418
- style: { width: '100%', minWidth: '100px' },
419
- showNumber: true,
420
- max: zdjj,
421
- min: zxjj,
422
- disabled: !_editable
423
- }, getFieldProps('je', {
424
- initialValue: je,
425
- rules: [{ required: _required, message: '\u8BF7\u8F93\u5165' + fieldMap.JE.title }],
426
- onChange: _this.onChangeStepper
427
- })))
428
- },
429
- fieldMap.JE.title
430
- );
431
- }
432
- });
433
- }
434
- } else {
435
- //分等级的,每个等级都是固定金额,但金额要跟着等级变化
436
- dataList.push({
437
- title: fieldMap.JE.title,
438
- text: gdjjBydj,
439
- required: _required,
440
- render: function render() {
441
- return _react2.default.createElement(
442
- _inputItem2.default,
443
- _extends({
444
- className: 'nh-input-item',
445
- placeholder: '\u8BF7\u8F93\u5165',
446
- editable: false,
447
- disabled: !_editable
448
- }, _this.requiredParams(_required, 'je'), getFieldProps('je', {
449
- initialValue: gdjjBydj,
450
- rules: [{ required: _required, message: '\u8BF7\u8F93\u5165' + fieldMap.JE.title }]
451
- })),
452
- fieldMap.JE.title
453
- );
454
- }
455
- });
456
- }
457
- }
458
-
459
- if (fieldMap.PJZQ && fieldMap.PJZQ.sfxs === '1') {
460
- var _required2 = fieldMap.PJZQ.sfbt === "1" ? true : false;
461
- var _editable2 = fieldMap.PJZQ.sfbj === "1" ? true : false;
462
- dataList.push({
463
- id: 'pjzq',
464
- title: fieldMap.PJZQ.title,
465
- text: pjzq,
466
- required: _required2,
467
- render: function render() {
468
- getFieldProps('pjzq', {
469
- initialValue: pjzqdm
470
- });
471
- return _react2.default.createElement(
472
- _inputItem2.default,
473
- {
474
- className: 'nh-input-item',
475
- placeholder: '\u8BF7\u8F93\u5165',
476
- editable: false,
477
- disabled: !_editable2,
478
- value: pjzq
479
- },
480
- fieldMap.PJZQ.title
481
- );
482
- }
483
-
484
- });
485
- }
486
- if (fieldMap.SQLY && fieldMap.SQLY.sfxs === '1') {
487
- var _required3 = fieldMap.SQLY.sfbt === "1" ? true : false;
488
- var _editable3 = fieldMap.SQLY.sfbj === "1" ? true : false;
489
- dataList.push({
490
- id: 'sqly',
491
- title: fieldMap.SQLY.title,
492
- text: sqly,
493
- required: _required3,
494
- isUpload: false,
495
- render: function render() {
496
- return _react2.default.createElement(_textareaItem2.default, _extends({
497
- title: fieldMap.SQLY.title,
498
- placeholder: '\u8BF7\u8F93\u5165',
499
- rows: 3,
500
- count: 500,
501
- editable: _editable3,
502
- disabled: !_editable3
503
- }, _this.requiredParams(_required3, 'sqly'), getFieldProps('sqly', {
504
- initialValue: sqly,
505
- rules: [{ required: _required3, message: '\u8BF7\u8F93\u5165' + fieldMap.SQLY.title }],
506
- onChange: function onChange(v) {
507
- return _this.setState({ sqly: v });
508
- }
509
- })));
510
- }
511
- });
512
- }
513
-
514
- if (fieldMap.FJID && fieldMap.FJID.sfxs === '1') {
515
- var _required4 = fieldMap.FJID.sfbt === "1" ? true : false;
516
- var _editable4 = fieldMap.FJID.sfbj === "1" ? true : false;
517
- dataList.push({
518
- id: 'fjid',
519
- title: fieldMap.FJID.title,
520
- text: fjid,
521
- required: _required4,
522
- isUpload: true,
523
- render: function render() {
524
- return _react2.default.createElement(
525
- _list2.default.Item,
526
- _this.requiredParams(_required4, 'fjid'),
527
- _react2.default.createElement(
528
- 'label',
529
- { className: (0, _classnames2.default)({ 'nh-dynamic-form-disabled': !_editable4 }) },
530
- fieldMap.FJID.title
531
- ),
532
- _react2.default.createElement(_index2.default, _extends({
533
- serviceMark: 'sm-scholarship',
534
- moduleName: '奖学金',
535
- isEdit: _this.props.isEdit && _editable4,
536
- numberOfLimit: 10,
537
- numberOfSize: 5
538
- }, getFieldProps('fjid', {
539
- initialValue: fjid,
540
- rules: [{ required: _required4, message: '请上传附件' }]
541
- })))
542
- );
543
- },
544
- renderView: function renderView() {
545
- return _react2.default.createElement(_index2.default, {
546
- serviceMark: 'sm-scholarship',
547
- moduleName: '奖学金',
548
- isEdit: false,
549
- value: fjid
550
- });
551
- }
552
- });
553
- }
554
- return dataList;
555
- };
556
-
557
- _this.state = {
558
- mxsm: 1, //明细数目
559
- mxid: undefined, //明细id
560
- djmc: undefined, //等级名称
561
- sfgdje: undefined, //是否固定金额
562
- gdjj: undefined, //固定奖金
563
- zdjj: 0, //最大奖金
564
- zxjj: 0, //最小奖金
565
- pjzqdm: undefined, //评奖周期代码
566
- pjzq: undefined, //评奖周期
567
- sffdj: undefined, //是否分等级
568
- fjid: undefined,
569
- sqly: undefined,
570
- je: undefined,
571
- djxx: [], //等级信息,用于存有多个等级的情况
572
- mxidxx: [], //分等级情况下,记录下所有的mxid
573
- gdjjxx: [], //分等级情况下,记录下所有的固定金额,跟mxidxx对应
574
- gdjjBydj: undefined //用于分等级情况下,根据不同等级显示不同金额
575
- };
576
-
577
- return _this;
578
- }
579
-
580
- //改变等级
581
-
582
- //步进器改变
583
-
584
-
585
- _createClass(EditInitForm, [{
586
- key: 'render',
587
- value: function render() {
588
- var _props = this.props,
589
- form = _props.form,
590
- isEdit = _props.isEdit,
591
- fieldMap = _props.fieldMap,
592
- title = _props.title;
593
-
594
- var dataList = this.getDataList(fieldMap);
595
- if (isEdit) {
596
- return _react2.default.createElement(
597
- 'form',
598
- null,
599
- _react2.default.createElement(
600
- _list2.default,
601
- { renderHeader: function renderHeader() {
602
- return title;
603
- } },
604
- dataList.map(function (item, index) {
605
- return _react2.default.createElement(
606
- 'div',
607
- { key: index, className: (0, _classnames2.default)('nh-dynamic-list-item', { 'nh-dynamic-required': item.required }) },
608
- item.render !== undefined ? item.render() : null
609
- );
610
- })
611
- ),
612
- _react2.default.createElement(_whiteSpace2.default, { size: 'lg' })
613
- );
614
- }
615
- return _react2.default.createElement(
616
- 'div',
617
- null,
618
- _react2.default.createElement(
619
- _card2.default,
620
- { full: true },
621
- _react2.default.createElement(_card2.default.Header, {
622
- title: _react2.default.createElement(
623
- 'div',
624
- { style: { borderLeft: '3px solid #1890ff', paddingLeft: '10px' } },
625
- title
626
- )
627
- }),
628
- _react2.default.createElement(
629
- _card2.default.Body,
630
- null,
631
- dataList.map(function (item, index) {
632
- if (item.isUpload) {
633
- return _react2.default.createElement(
634
- 'div',
635
- { key: index },
636
- _react2.default.createElement(
637
- 'font',
638
- { color: 'grey' },
639
- item.title,
640
- '\uFF1A '
641
- ),
642
- item.renderView()
643
- );
644
- }
645
- return _react2.default.createElement(
646
- 'div',
647
- null,
648
- _react2.default.createElement(
649
- 'font',
650
- { color: 'grey' },
651
- item.title,
652
- '\uFF1A '
653
- ),
654
- item.text,
655
- _react2.default.createElement('br', null)
656
- );
657
- })
658
- )
659
- ),
660
- _react2.default.createElement(_whiteSpace2.default, { size: 'lg' })
661
- );
662
- }
663
- }]);
664
-
665
- return EditInitForm;
666
- }(_react2.default.Component);
667
-
668
- var EditForm = (0, _rcForm.createForm)()(EditInitForm);
669
- exports.default = EditForm;