dlt-for-react 1.0.24 → 1.1.1
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.
- package/README.md +12 -2
- package/lib/components/Button/index.js +79 -0
- package/lib/components/HqSelector/HqLsrySelector/index.js +3 -5
- package/lib/components/HqSelector/HqRySelector/index.js +3 -5
- package/lib/components/HqSelector/HqWzSelector/index.js +3 -5
- package/lib/components/KyEditableTable/component.js +3 -5
- package/lib/components/KyEditableTable/index.js +7 -13
- package/lib/components/KyExcel/index.js +3 -5
- package/lib/components/KyInputPicker/render.js +13 -43
- package/lib/components/KyInputPicker/setting-checkbox.js +3 -5
- package/lib/components/KyInputPicker/setting-multiSelect.js +3 -5
- package/lib/components/KyInputPicker/setting-nhcascader.js +3 -5
- package/lib/components/KyInputPicker/setting-select.js +3 -5
- package/lib/components/KyInputPicker/setting-stu-selector.js +3 -5
- package/lib/components/KyInputPicker/setting-tea-selector.js +3 -5
- package/lib/components/KyTable/checkButtons.js +4 -7
- package/lib/components/KyTree/index.js +6 -16
- package/lib/components/KyUpload/index.js +10 -20
- package/lib/components/NHAuditPanel/config/Axios.js +263 -0
- package/lib/components/NHAuditPanel/config/api.js +479 -0
- package/lib/components/NHAuditPanel/config/data.js +156 -0
- package/lib/components/NHAuditPanel/config/typeMap.js +1234 -0
- package/lib/components/NHAuditPanel/config/uiValidate.js +92 -0
- package/lib/components/NHAuditPanel/index.js +413 -0
- package/lib/components/NHAuditPanel/node.js +619 -0
- package/lib/components/NHCascader/index.js +355 -0
- package/lib/components/NHCheckboxGroup/index.js +135 -0
- package/lib/components/NHDynamicFormShow/baseInfo/index.js +194 -0
- package/lib/components/NHDynamicFormShow/custom/index.js +553 -0
- package/lib/components/NHDynamicFormShow/customModule/common/CommonMethod.js +43 -0
- package/lib/components/NHDynamicFormShow/customModule/czxy/qgzx/EditForm.js +1113 -0
- package/lib/components/NHDynamicFormShow/customModule/czxy/qgzx/index.js +263 -0
- package/lib/components/NHDynamicFormShow/customModule/czxy/xfjm/EditForm.js +880 -0
- package/lib/components/NHDynamicFormShow/customModule/czxy/xfjm/index.js +171 -0
- package/lib/components/NHDynamicFormShow/customModule/czxy/zxj/EditForm.js +865 -0
- package/lib/components/NHDynamicFormShow/customModule/czxy/zxj/index.js +138 -0
- package/lib/components/NHDynamicFormShow/customModule/eszy/zsxxhd/EditForm.js +571 -0
- package/lib/components/NHDynamicFormShow/customModule/eszy/zsxxhd/index.js +147 -0
- package/lib/components/NHDynamicFormShow/customModule/eszy/zybjtz/EditForm.js +474 -0
- package/lib/components/NHDynamicFormShow/customModule/eszy/zybjtz/index.js +139 -0
- package/lib/components/NHDynamicFormShow/customModule/gnyxy/cqzg/EditForm.js +506 -0
- package/lib/components/NHDynamicFormShow/customModule/gnyxy/cqzg/index.js +143 -0
- package/lib/components/NHDynamicFormShow/customModule/gnyxy/gwsb/EditForm.js +1074 -0
- package/lib/components/NHDynamicFormShow/customModule/gnyxy/gwsb/index.js +172 -0
- package/lib/components/NHDynamicFormShow/customModule/gnyxy/qjgl/EditForm.js +927 -0
- package/lib/components/NHDynamicFormShow/customModule/gnyxy/qjgl/index.js +195 -0
- package/lib/components/NHDynamicFormShow/customModule/gnyxy/sxsqj/EditForm.js +1064 -0
- package/lib/components/NHDynamicFormShow/customModule/gnyxy/sxsqj/index.js +183 -0
- package/lib/components/NHDynamicFormShow/customModule/hblgxy/jxj/EditForm.js +763 -0
- package/lib/components/NHDynamicFormShow/customModule/hblgxy/jxj/index.js +137 -0
- package/lib/components/NHDynamicFormShow/customModule/hblgxy/lzjxj/EditForm.js +819 -0
- package/lib/components/NHDynamicFormShow/customModule/hblgxy/lzjxj/index.js +137 -0
- package/lib/components/NHDynamicFormShow/customModule/hblgxy/qgzx/EditForm.js +700 -0
- package/lib/components/NHDynamicFormShow/customModule/hblgxy/qgzx/index.js +162 -0
- package/lib/components/NHDynamicFormShow/customModule/hblgxy/xsqj/EditForm.js +743 -0
- package/lib/components/NHDynamicFormShow/customModule/hblgxy/xsqj/index.js +177 -0
- package/lib/components/NHDynamicFormShow/customModule/hblgxy/zxj/EditForm.js +848 -0
- package/lib/components/NHDynamicFormShow/customModule/hblgxy/zxj/index.js +138 -0
- package/lib/components/NHDynamicFormShow/customModule/hljwgy/qjgl/EditForm.js +777 -0
- package/lib/components/NHDynamicFormShow/customModule/hljwgy/qjgl/index.js +161 -0
- package/lib/components/NHDynamicFormShow/customModule/hljwgy/xjgl/EditForm.js +706 -0
- package/lib/components/NHDynamicFormShow/customModule/hljwgy/xjgl/index.js +130 -0
- package/lib/components/NHDynamicFormShow/customModule/jhysxy/cfjcsq/cfjcEditForm.js +413 -0
- package/lib/components/NHDynamicFormShow/customModule/jhysxy/cfjcsq/index.js +135 -0
- package/lib/components/NHDynamicFormShow/customModule/jhysxy/xsqj/EditForm.js +1013 -0
- package/lib/components/NHDynamicFormShow/customModule/jhysxy/xsqj/index.js +175 -0
- package/lib/components/NHDynamicFormShow/customModule/jjrlx/EditForm.js +1345 -0
- package/lib/components/NHDynamicFormShow/customModule/jjrlx/index.js +274 -0
- package/lib/components/NHDynamicFormShow/customModule/jxj/EditForm.js +669 -0
- package/lib/components/NHDynamicFormShow/customModule/jxj/index.js +134 -0
- package/lib/components/NHDynamicFormShow/customModule/jxsl/fqkns/EditForm.js +378 -0
- package/lib/components/NHDynamicFormShow/customModule/jxsl/fqkns/index.js +120 -0
- package/lib/components/NHDynamicFormShow/customModule/jxsl/xwryfjjd/EditForm.js +638 -0
- package/lib/components/NHDynamicFormShow/customModule/jxsl/xwryfjjd/index.js +133 -0
- package/lib/components/NHDynamicFormShow/customModule/qgzx/EditForm.js +965 -0
- package/lib/components/NHDynamicFormShow/customModule/qgzx/index.js +237 -0
- package/lib/components/NHDynamicFormShow/customModule/qjgl/EditForm.js +823 -0
- package/lib/components/NHDynamicFormShow/customModule/qjgl/index.js +188 -0
- package/lib/components/NHDynamicFormShow/customModule/rcgl/jqlssq/EditForm.js +401 -0
- package/lib/components/NHDynamicFormShow/customModule/rcgl/jqlssq/index.js +472 -0
- package/lib/components/NHDynamicFormShow/customModule/rcgl/tssq/EditForm.js +304 -0
- package/lib/components/NHDynamicFormShow/customModule/rcgl/tssq/NHCascader/index.js +375 -0
- package/lib/components/NHDynamicFormShow/customModule/rcgl/tssq/NHInputPicker/RadioGroup.js +118 -0
- package/lib/components/NHDynamicFormShow/customModule/rcgl/tssq/NHInputPicker/index.js +62 -0
- package/lib/components/NHDynamicFormShow/customModule/rcgl/tssq/NHInputPicker/input-const.js +55 -0
- package/lib/components/NHDynamicFormShow/customModule/rcgl/tssq/NHInputPicker/render.js +1238 -0
- package/lib/components/NHDynamicFormShow/customModule/rcgl/tssq/index.js +375 -0
- package/lib/components/NHDynamicFormShow/customModule/rych/collective/EditForm.js +554 -0
- package/lib/components/NHDynamicFormShow/customModule/rych/collective/index.js +130 -0
- package/lib/components/NHDynamicFormShow/customModule/rych/personal/EditForm.js +542 -0
- package/lib/components/NHDynamicFormShow/customModule/rych/personal/index.js +133 -0
- package/lib/components/NHDynamicFormShow/customModule/sxgy/rych/collective/EditForm.js +575 -0
- package/lib/components/NHDynamicFormShow/customModule/sxgy/rych/collective/index.js +130 -0
- package/lib/components/NHDynamicFormShow/customModule/sxgy/rych/personal/EditForm.js +563 -0
- package/lib/components/NHDynamicFormShow/customModule/sxgy/rych/personal/index.js +133 -0
- package/lib/components/NHDynamicFormShow/customModule/whcz/qjgl/EditForm.js +745 -0
- package/lib/components/NHDynamicFormShow/customModule/whcz/qjgl/index.js +164 -0
- package/lib/components/NHDynamicFormShow/customModule/whcz/rccrxy/EditForm.js +587 -0
- package/lib/components/NHDynamicFormShow/customModule/whcz/rccrxy/index.js +143 -0
- package/lib/components/NHDynamicFormShow/customModule/whdlqjgl/EditForm.js +743 -0
- package/lib/components/NHDynamicFormShow/customModule/whdlqjgl/index.js +172 -0
- package/lib/components/NHDynamicFormShow/customModule/whgc/jjrlx/EditForm.js +1410 -0
- package/lib/components/NHDynamicFormShow/customModule/whgc/jjrlx/index.js +274 -0
- package/lib/components/NHDynamicFormShow/customModule/whgc/jxj/EditForm.js +755 -0
- package/lib/components/NHDynamicFormShow/customModule/whgc/jxj/index.js +130 -0
- package/lib/components/NHDynamicFormShow/customModule/whgc/qjgl/EditForm.js +814 -0
- package/lib/components/NHDynamicFormShow/customModule/whgc/qjgl/index.js +188 -0
- package/lib/components/NHDynamicFormShow/customModule/whgc/zxj/EditForm.js +769 -0
- package/lib/components/NHDynamicFormShow/customModule/whgc/zxj/index.js +130 -0
- package/lib/components/NHDynamicFormShow/customModule/whgcrych/EditForm.js +1004 -0
- package/lib/components/NHDynamicFormShow/customModule/whgcrych/index.js +126 -0
- package/lib/components/NHDynamicFormShow/customModule/whtl/jsrzsq/EditForm.js +503 -0
- package/lib/components/NHDynamicFormShow/customModule/whtl/jsrzsq/index.js +149 -0
- package/lib/components/NHDynamicFormShow/customModule/whtlyhk/EditForm.js +379 -0
- package/lib/components/NHDynamicFormShow/customModule/whtlyhk/index.js +148 -0
- package/lib/components/NHDynamicFormShow/customModule/whtlzxj/EditForm.js +748 -0
- package/lib/components/NHDynamicFormShow/customModule/whtlzxj/index.js +135 -0
- package/lib/components/NHDynamicFormShow/customModule/whtlzy/jxj/EditForm.js +762 -0
- package/lib/components/NHDynamicFormShow/customModule/whtlzy/jxj/index.js +134 -0
- package/lib/components/NHDynamicFormShow/customModule/wjcf/cfjc/cfjcEditForm.js +682 -0
- package/lib/components/NHDynamicFormShow/customModule/wjcf/cfjc/index.js +135 -0
- package/lib/components/NHDynamicFormShow/customModule/wjcf/wjsb/index.js +152 -0
- package/lib/components/NHDynamicFormShow/customModule/wjcf/wjsb/wjsbEditForm.js +783 -0
- package/lib/components/NHDynamicFormShow/customModule/zxj/EditForm.js +764 -0
- package/lib/components/NHDynamicFormShow/customModule/zxj/index.js +138 -0
- package/lib/components/NHDynamicFormShow/customModule/zzsd/cfjcsq/cfjcEditForm.js +677 -0
- package/lib/components/NHDynamicFormShow/customModule/zzsd/cfjcsq/index.js +138 -0
- package/lib/components/NHDynamicFormShow/customModule/zzsd/qjgl/EditForm.js +1173 -0
- package/lib/components/NHDynamicFormShow/customModule/zzsd/qjgl/index.js +242 -0
- package/lib/components/NHDynamicFormShow/customModule/zzsd/rcgl/rcxwgrdj/IndividualRegistForm.js +862 -0
- package/lib/components/NHDynamicFormShow/customModule/zzsd/rcgl/rcxwgrdj/IndividualRegistIndex.js +201 -0
- package/lib/components/NHDynamicFormShow/customModule/zzsd/stuinfo/messageInfo.js +196 -0
- package/lib/components/NHDynamicFormShow/customModule/zzsd/wjsb/index.js +167 -0
- package/lib/components/NHDynamicFormShow/customModule/zzsd/wjsb/wjsbEditForm.js +1096 -0
- package/lib/components/NHDynamicFormShow/index.js +647 -0
- package/lib/components/NHDynamicFormShow/oneOnMany/cardForm/cardItem/index.js +279 -0
- package/lib/components/NHDynamicFormShow/oneOnMany/cardForm/index.js +206 -0
- package/lib/components/NHDynamicFormShow/oneOnMany/index.js +419 -0
- package/lib/components/NHDynamicFormShow/oneOnOne/EditForm.js +401 -0
- package/lib/components/NHDynamicFormShow/oneOnOne/index.js +271 -0
- package/lib/components/NHImagePicker/index.js +554 -0
- package/lib/components/NHInputPicker/RadioGroup.js +118 -0
- package/lib/components/NHInputPicker/index.js +62 -0
- package/lib/components/NHInputPicker/input-const.js +55 -0
- package/lib/components/NHInputPicker/render.js +1271 -0
- package/lib/components/NHListView/index.js +374 -0
- package/lib/components/NHMapGeolocation/index.js +537 -0
- package/lib/components/NHMapGeolocation/initMap/initGdMap.js +104 -0
- package/lib/components/NHMapGeolocation/initMap/initTencentMap.js +138 -0
- package/lib/components/NHMapGeolocation/style.js +51 -0
- package/lib/components/NHMultiSelect/index.js +272 -0
- package/lib/components/NHRadioGroup/index.js +118 -0
- package/lib/components/NHSelect/index.js +364 -0
- package/lib/components/NHTreeMenu/index.js +126 -0
- package/lib/components/NHTreeMenu/treeNode.js +164 -0
- package/lib/components/StuSelector/index.js +611 -0
- package/lib/index.js +187 -118
- package/lib/layouts/KyInputPicker/edit-page.js +585 -0
- package/lib/layouts/KyInputPicker/index.js +220 -0
- package/lib/layouts/KyInputPicker/input-const.js +134 -0
- package/lib/layouts/KyInputPicker/render.js +2477 -0
- package/lib/layouts/KyInputPicker/setting-checkbox.js +850 -0
- package/lib/layouts/KyInputPicker/setting-datepicker.js +430 -0
- package/lib/layouts/KyInputPicker/setting-datetimepicker.js +443 -0
- package/lib/layouts/KyInputPicker/setting-input.js +555 -0
- package/lib/layouts/KyInputPicker/setting-inputNumber.js +612 -0
- package/lib/layouts/KyInputPicker/setting-monthpicker.js +434 -0
- package/lib/layouts/KyInputPicker/setting-multiSelect.js +532 -0
- package/lib/layouts/KyInputPicker/setting-nhcascader.js +584 -0
- package/lib/layouts/KyInputPicker/setting-old-upload.js +428 -0
- package/lib/layouts/KyInputPicker/setting-radio.js +468 -0
- package/lib/layouts/KyInputPicker/setting-rangepicker.js +466 -0
- package/lib/layouts/KyInputPicker/setting-select.js +534 -0
- package/lib/layouts/KyInputPicker/setting-stu-selector.js +507 -0
- package/lib/layouts/KyInputPicker/setting-switch.js +274 -0
- package/lib/layouts/KyInputPicker/setting-tea-selector.js +507 -0
- package/lib/layouts/KyInputPicker/setting-textarea.js +619 -0
- package/lib/layouts/KyInputPicker/setting-timepicker.js +437 -0
- package/lib/layouts/KyInputPicker/setting-upload.js +766 -0
- package/lib/layouts/KyModal/buildTitle.js +81 -0
- package/lib/layouts/KyModal/dragM.js +127 -0
- package/lib/layouts/KyModal/index.js +321 -0
- package/lib/layouts/KyPreview/index.js +219 -0
- package/lib/layouts/KyUpload/index.js +1155 -0
- package/lib/layouts/LeftMenu/index.js +5 -11
- package/lib/layouts/NavigationBar/index.js +4 -10
- package/lib/layouts/Top/editPassWord.js +5 -7
- package/lib/layouts/Top/index.js +6 -20
- package/lib/layouts/TopMenu/index.js +11 -14
- package/lib/layouts/layout/index.js +7 -13
- package/lib/layouts/{Login → login}/index-pre.js +3 -5
- package/lib/layouts/{Login → login}/index.js +6 -8
- package/lib/layouts/{Login → login}/login.js +8 -17
- package/lib/layouts/mixTop/index.js +13 -28
- package/lib/layouts/settingDrawer/index.js +3 -5
- package/lib/routes/AuthorizedRoute.js +7 -13
- package/lib/utils/NHCore.js +46 -2
- package/lib/utils/browserJudge.js +33 -0
- package/lib/utils/common.js +18 -20
- package/lib/utils/createUuid.js +11 -31
- package/lib/utils/device.js +44 -0
- package/lib/utils/dynamicLoadCss.js +14 -0
- package/lib/utils/dynamicLoadJs.js +21 -0
- package/lib/utils/getLoginUser.js +1 -1
- package/lib/utils/getSize.js +2 -11
- package/lib/utils/getStyle.js +26 -0
- package/lib/utils/getSuitHeight.js +49 -0
- package/lib/utils/hasAuth.js +11 -0
- package/lib/utils/index.js +1 -34
- package/lib/utils/loadJS.js +40 -0
- package/package.json +1 -1
- /package/lib/layouts/{Login → login}/lyPassword.js +0 -0
|
@@ -0,0 +1,149 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
|
|
7
|
+
var _toast = require('antd-mobile/lib/toast');
|
|
8
|
+
|
|
9
|
+
var _toast2 = _interopRequireDefault(_toast);
|
|
10
|
+
|
|
11
|
+
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; };
|
|
12
|
+
|
|
13
|
+
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; }; }();
|
|
14
|
+
|
|
15
|
+
require('antd-mobile/lib/toast/style/css');
|
|
16
|
+
|
|
17
|
+
var _react = require('react');
|
|
18
|
+
|
|
19
|
+
var _react2 = _interopRequireDefault(_react);
|
|
20
|
+
|
|
21
|
+
var _propTypes = require('prop-types');
|
|
22
|
+
|
|
23
|
+
var _propTypes2 = _interopRequireDefault(_propTypes);
|
|
24
|
+
|
|
25
|
+
var _NHFetch = require('../../../../../utils/NHFetch');
|
|
26
|
+
|
|
27
|
+
var _NHFetch2 = _interopRequireDefault(_NHFetch);
|
|
28
|
+
|
|
29
|
+
var _EditForm = require('./EditForm');
|
|
30
|
+
|
|
31
|
+
var _EditForm2 = _interopRequireDefault(_EditForm);
|
|
32
|
+
|
|
33
|
+
var _moment = require('moment');
|
|
34
|
+
|
|
35
|
+
var _moment2 = _interopRequireDefault(_moment);
|
|
36
|
+
|
|
37
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
38
|
+
|
|
39
|
+
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
40
|
+
|
|
41
|
+
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; }
|
|
42
|
+
|
|
43
|
+
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; }
|
|
44
|
+
|
|
45
|
+
/**
|
|
46
|
+
* 教师入住申请自定义表单
|
|
47
|
+
* @author: zengxiangkai
|
|
48
|
+
* @date: 2020-06-04 16:26:49
|
|
49
|
+
*/
|
|
50
|
+
var JsrzsqEditForm = function (_React$Component) {
|
|
51
|
+
_inherits(JsrzsqEditForm, _React$Component);
|
|
52
|
+
|
|
53
|
+
function JsrzsqEditForm(props) {
|
|
54
|
+
_classCallCheck(this, JsrzsqEditForm);
|
|
55
|
+
|
|
56
|
+
var _this = _possibleConstructorReturn(this, (JsrzsqEditForm.__proto__ || Object.getPrototypeOf(JsrzsqEditForm)).call(this, props));
|
|
57
|
+
|
|
58
|
+
_this.validate = function (func) {
|
|
59
|
+
_this.nhEditForm.validateFields(function (err, formData) {
|
|
60
|
+
if (err) {
|
|
61
|
+
func(false);
|
|
62
|
+
} else {
|
|
63
|
+
_this.setState({ formData: formData }, function () {
|
|
64
|
+
func(true);
|
|
65
|
+
});
|
|
66
|
+
}
|
|
67
|
+
});
|
|
68
|
+
};
|
|
69
|
+
|
|
70
|
+
_this.save = function (func, failCallback) {
|
|
71
|
+
var _this$props = _this.props,
|
|
72
|
+
processApplyId = _this$props.processApplyId,
|
|
73
|
+
objId = _this$props.objId,
|
|
74
|
+
pkid = _this$props.pkid;
|
|
75
|
+
var formData = _this.state.formData;
|
|
76
|
+
|
|
77
|
+
var param = formData;
|
|
78
|
+
var roomid = param.sqcwid[1];
|
|
79
|
+
param.pkid = pkid;
|
|
80
|
+
param.xsid = objId;
|
|
81
|
+
param.lcslid = processApplyId;
|
|
82
|
+
param.sqcwid = param.sqcwid ? param.sqcwid[2] : '';
|
|
83
|
+
param.roomid = roomid;
|
|
84
|
+
param.rzsj = param.rzsj ? (0, _moment2.default)(param.rzsj).format("YYYY-MM-DD") : '';
|
|
85
|
+
// 替换紧急联系人电话字符串中的空格
|
|
86
|
+
param.lxfs = param.lxfs ? param.lxfs.replace(/\s+/g, '') : '';
|
|
87
|
+
(0, _NHFetch2.default)('api/zhxg-gyrcgl/whtl/rzsq/save', 'POST', param).then(function (res) {
|
|
88
|
+
if (res && res.code === 200) {
|
|
89
|
+
if (res.data === 2) {
|
|
90
|
+
failCallback && failCallback();
|
|
91
|
+
_toast2.default.fail("不能申请入住异性房间,请重新选择房间");
|
|
92
|
+
} else {
|
|
93
|
+
func();
|
|
94
|
+
}
|
|
95
|
+
} else {
|
|
96
|
+
failCallback && failCallback();
|
|
97
|
+
_toast2.default.fail("申请入住失败,请重新申请");
|
|
98
|
+
}
|
|
99
|
+
});
|
|
100
|
+
};
|
|
101
|
+
|
|
102
|
+
_this.state = {
|
|
103
|
+
formData: {}
|
|
104
|
+
};
|
|
105
|
+
return _this;
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
/**
|
|
109
|
+
* 校验该分类表单是否全部填写完成,该方法必须存在
|
|
110
|
+
*/
|
|
111
|
+
|
|
112
|
+
|
|
113
|
+
//保存
|
|
114
|
+
|
|
115
|
+
|
|
116
|
+
_createClass(JsrzsqEditForm, [{
|
|
117
|
+
key: 'render',
|
|
118
|
+
value: function render() {
|
|
119
|
+
var _this2 = this;
|
|
120
|
+
|
|
121
|
+
return _react2.default.createElement(_EditForm2.default, _extends({
|
|
122
|
+
ref: function ref(form) {
|
|
123
|
+
_this2.nhEditForm = form;
|
|
124
|
+
}
|
|
125
|
+
}, this.props));
|
|
126
|
+
}
|
|
127
|
+
}]);
|
|
128
|
+
|
|
129
|
+
return JsrzsqEditForm;
|
|
130
|
+
}(_react2.default.Component);
|
|
131
|
+
|
|
132
|
+
exports.default = JsrzsqEditForm;
|
|
133
|
+
|
|
134
|
+
|
|
135
|
+
JsrzsqEditForm.defaultProps = {
|
|
136
|
+
fieldMap: {},
|
|
137
|
+
params: {}
|
|
138
|
+
};
|
|
139
|
+
|
|
140
|
+
JsrzsqEditForm.propTypes = {
|
|
141
|
+
pkid: _propTypes2.default.string, //业务表主键ID
|
|
142
|
+
objId: _propTypes2.default.string, //对象ID
|
|
143
|
+
processId: _propTypes2.default.string, //流程ID
|
|
144
|
+
processApplyId: _propTypes2.default.string, //流程申请主键ID
|
|
145
|
+
fieldMap: _propTypes2.default.object, //字段信息,可以通过该对象获取到该字段,是否可以显示(sfxs)、是否可以编辑(sfbj)、是否必填等信息(sfbt)
|
|
146
|
+
params: _propTypes2.default.object, //参数集合,主要通过该参数集合给自定义面板传参
|
|
147
|
+
isEdit: _propTypes2.default.bool, //是否是编辑状态
|
|
148
|
+
title: _propTypes2.default.string
|
|
149
|
+
};
|
|
@@ -0,0 +1,379 @@
|
|
|
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 _list = require("antd-mobile/lib/list");
|
|
16
|
+
|
|
17
|
+
var _list2 = _interopRequireDefault(_list);
|
|
18
|
+
|
|
19
|
+
var _textareaItem = require("antd-mobile/lib/textarea-item");
|
|
20
|
+
|
|
21
|
+
var _textareaItem2 = _interopRequireDefault(_textareaItem);
|
|
22
|
+
|
|
23
|
+
var _toast = require("antd-mobile/lib/toast");
|
|
24
|
+
|
|
25
|
+
var _toast2 = _interopRequireDefault(_toast);
|
|
26
|
+
|
|
27
|
+
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; };
|
|
28
|
+
|
|
29
|
+
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; }; }();
|
|
30
|
+
|
|
31
|
+
require("antd-mobile/lib/card/style/css");
|
|
32
|
+
|
|
33
|
+
require("antd-mobile/lib/white-space/style/css");
|
|
34
|
+
|
|
35
|
+
require("antd-mobile/lib/list/style/css");
|
|
36
|
+
|
|
37
|
+
require("antd-mobile/lib/textarea-item/style/css");
|
|
38
|
+
|
|
39
|
+
require("antd-mobile/lib/toast/style/css");
|
|
40
|
+
|
|
41
|
+
var _react = require("react");
|
|
42
|
+
|
|
43
|
+
var _react2 = _interopRequireDefault(_react);
|
|
44
|
+
|
|
45
|
+
var _moment = require("moment");
|
|
46
|
+
|
|
47
|
+
var _moment2 = _interopRequireDefault(_moment);
|
|
48
|
+
|
|
49
|
+
var _NHFetch = require("../../../../utils/NHFetch");
|
|
50
|
+
|
|
51
|
+
var _NHFetch2 = _interopRequireDefault(_NHFetch);
|
|
52
|
+
|
|
53
|
+
var _rcForm = require("rc-form");
|
|
54
|
+
|
|
55
|
+
var _classnames = require("classnames");
|
|
56
|
+
|
|
57
|
+
var _classnames2 = _interopRequireDefault(_classnames);
|
|
58
|
+
|
|
59
|
+
var _index = require("../../../NHImagePicker/index");
|
|
60
|
+
|
|
61
|
+
var _index2 = _interopRequireDefault(_index);
|
|
62
|
+
|
|
63
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
64
|
+
|
|
65
|
+
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
66
|
+
|
|
67
|
+
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; }
|
|
68
|
+
|
|
69
|
+
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; }
|
|
70
|
+
|
|
71
|
+
var EditInitForm = function (_React$Component) {
|
|
72
|
+
_inherits(EditInitForm, _React$Component);
|
|
73
|
+
|
|
74
|
+
function EditInitForm(props) {
|
|
75
|
+
_classCallCheck(this, EditInitForm);
|
|
76
|
+
|
|
77
|
+
var _this = _possibleConstructorReturn(this, (EditInitForm.__proto__ || Object.getPrototypeOf(EditInitForm)).call(this, props));
|
|
78
|
+
|
|
79
|
+
_this.componentDidMount = function () {
|
|
80
|
+
_this.initData();
|
|
81
|
+
};
|
|
82
|
+
|
|
83
|
+
_this.initData = function () {
|
|
84
|
+
var pkid = _this.props.pkid;
|
|
85
|
+
|
|
86
|
+
_this.getData(pkid);
|
|
87
|
+
_this.getMryhkh();
|
|
88
|
+
};
|
|
89
|
+
|
|
90
|
+
_this.getData = function (pkid) {
|
|
91
|
+
//通过PKID去查询是否有申请数据,有说明是审核
|
|
92
|
+
var t = new Date().getTime();
|
|
93
|
+
(0, _NHFetch2.default)('api/sm-student/openapi/getYhkxx/' + pkid, 'GET', t).then(function (res) {
|
|
94
|
+
if (res && res.code === 200) {
|
|
95
|
+
var yhkxx = res.data;
|
|
96
|
+
if (yhkxx != null) {
|
|
97
|
+
_this.setState({
|
|
98
|
+
khyh: yhkxx.khyh,
|
|
99
|
+
yhkh: yhkxx.yhkh
|
|
100
|
+
});
|
|
101
|
+
}
|
|
102
|
+
} else {
|
|
103
|
+
_toast2.default.fail("调用接口失败");
|
|
104
|
+
}
|
|
105
|
+
});
|
|
106
|
+
};
|
|
107
|
+
|
|
108
|
+
_this.getMryhkh = function () {
|
|
109
|
+
var setFieldsValue = _this.props.form.setFieldsValue;
|
|
110
|
+
|
|
111
|
+
(0, _NHFetch2.default)('api/zhxg-xtgl/openapi/getCsszByCsbz', 'GET', { csbz: "ZXJ_MRYHKH" }).then(function (res) {
|
|
112
|
+
if (res && res.code === 200) {
|
|
113
|
+
var param = res.data;
|
|
114
|
+
console.log("param.CSZ:" + param.csz);
|
|
115
|
+
_this.setState({
|
|
116
|
+
mryhkh: param.csz ? param.csz : ''
|
|
117
|
+
});
|
|
118
|
+
// setFieldsValue({mryhkh:param.CSZ ? param.CSZ:''})
|
|
119
|
+
} else {
|
|
120
|
+
_toast2.default.fail("获取默认银行卡号失败");
|
|
121
|
+
}
|
|
122
|
+
});
|
|
123
|
+
};
|
|
124
|
+
|
|
125
|
+
_this.requiredParams = function (required, id) {
|
|
126
|
+
var getFieldError = _this.props.form.getFieldError;
|
|
127
|
+
|
|
128
|
+
return {
|
|
129
|
+
error: getFieldError(id) !== undefined
|
|
130
|
+
};
|
|
131
|
+
};
|
|
132
|
+
|
|
133
|
+
_this.getDataList = function (fieldMap) {
|
|
134
|
+
console.log(fieldMap);
|
|
135
|
+
var _this$props$form = _this.props.form,
|
|
136
|
+
getFieldProps = _this$props$form.getFieldProps,
|
|
137
|
+
getFieldError = _this$props$form.getFieldError;
|
|
138
|
+
var _this$state = _this.state,
|
|
139
|
+
khyh = _this$state.khyh,
|
|
140
|
+
yhkh = _this$state.yhkh,
|
|
141
|
+
mryhkh = _this$state.mryhkh;
|
|
142
|
+
|
|
143
|
+
var dataList = [];
|
|
144
|
+
|
|
145
|
+
//开户银行
|
|
146
|
+
if (fieldMap.KHYH && fieldMap.KHYH.sfxs === '1') {
|
|
147
|
+
|
|
148
|
+
var required = fieldMap.KHYH.sfbt === "1";
|
|
149
|
+
var editable = fieldMap.KHYH.sfbj === "1";
|
|
150
|
+
|
|
151
|
+
dataList.push({
|
|
152
|
+
title: '开户银行',
|
|
153
|
+
text: khyh,
|
|
154
|
+
render: function render() {
|
|
155
|
+
return _react2.default.createElement(_textareaItem2.default, _extends({
|
|
156
|
+
className: "nh-textarea-item",
|
|
157
|
+
title: required ? _react2.default.createElement(
|
|
158
|
+
"div",
|
|
159
|
+
null,
|
|
160
|
+
_react2.default.createElement(
|
|
161
|
+
"span",
|
|
162
|
+
{ style: { color: 'red' } },
|
|
163
|
+
"*"
|
|
164
|
+
),
|
|
165
|
+
"\u5F00\u6237\u94F6\u884C"
|
|
166
|
+
) : _react2.default.createElement(
|
|
167
|
+
"span",
|
|
168
|
+
null,
|
|
169
|
+
"\u5F00\u6237\u94F6\u884C"
|
|
170
|
+
),
|
|
171
|
+
placeholder: "\u8BF7\u8F93\u5165\u5F00\u6237\u94F6\u884C",
|
|
172
|
+
"data-seed": "logId",
|
|
173
|
+
rows: 1,
|
|
174
|
+
count: 30,
|
|
175
|
+
editable: editable
|
|
176
|
+
}, getFieldProps('khyh', {
|
|
177
|
+
initialValue: khyh,
|
|
178
|
+
rules: [{ required: required, message: '请输入开户银行' }]
|
|
179
|
+
})));
|
|
180
|
+
}
|
|
181
|
+
});
|
|
182
|
+
}
|
|
183
|
+
|
|
184
|
+
//银行卡号
|
|
185
|
+
if (fieldMap.YHKH && fieldMap.YHKH.sfxs === '1') {
|
|
186
|
+
|
|
187
|
+
var _required = fieldMap.YHKH.sfbt === "1";
|
|
188
|
+
var _editable = fieldMap.YHKH.sfbj === "1";
|
|
189
|
+
|
|
190
|
+
dataList.push({
|
|
191
|
+
title: '银行卡号',
|
|
192
|
+
text: yhkh,
|
|
193
|
+
render: function render() {
|
|
194
|
+
return _react2.default.createElement(_textareaItem2.default, _extends({
|
|
195
|
+
className: "nh-textarea-item",
|
|
196
|
+
title: _required ? _react2.default.createElement(
|
|
197
|
+
"div",
|
|
198
|
+
null,
|
|
199
|
+
_react2.default.createElement(
|
|
200
|
+
"span",
|
|
201
|
+
{ style: { color: 'red' } },
|
|
202
|
+
"*"
|
|
203
|
+
),
|
|
204
|
+
"\u94F6\u884C\u5361\u53F7"
|
|
205
|
+
) : _react2.default.createElement(
|
|
206
|
+
"span",
|
|
207
|
+
null,
|
|
208
|
+
"\u94F6\u884C\u5361\u53F7"
|
|
209
|
+
),
|
|
210
|
+
"data-seed": "logId",
|
|
211
|
+
rows: 1,
|
|
212
|
+
count: 30,
|
|
213
|
+
editable: _editable
|
|
214
|
+
}, getFieldProps('yhkh', {
|
|
215
|
+
initialValue: yhkh,
|
|
216
|
+
rules: [{ required: _required, message: '请输入农业银行卡号' }]
|
|
217
|
+
})));
|
|
218
|
+
}
|
|
219
|
+
});
|
|
220
|
+
dataList.push({
|
|
221
|
+
title: '默认银行卡号',
|
|
222
|
+
text: mryhkh,
|
|
223
|
+
render: function render() {
|
|
224
|
+
return _react2.default.createElement(
|
|
225
|
+
"div",
|
|
226
|
+
{ style: { display: 'none' } },
|
|
227
|
+
_react2.default.createElement(_textareaItem2.default, _extends({
|
|
228
|
+
className: "nh-textarea-item",
|
|
229
|
+
title: "银行卡号",
|
|
230
|
+
"data-seed": "logId",
|
|
231
|
+
rows: 1,
|
|
232
|
+
count: 30,
|
|
233
|
+
editable: _editable
|
|
234
|
+
}, getFieldProps('mryhkh', {
|
|
235
|
+
initialValue: mryhkh,
|
|
236
|
+
rules: [{ message: '请输入农业银行卡号' }]
|
|
237
|
+
})))
|
|
238
|
+
);
|
|
239
|
+
}
|
|
240
|
+
});
|
|
241
|
+
}
|
|
242
|
+
|
|
243
|
+
return dataList;
|
|
244
|
+
};
|
|
245
|
+
|
|
246
|
+
_this.state = {
|
|
247
|
+
khyh: '', //开户银行
|
|
248
|
+
yhkh: '', //银行卡号
|
|
249
|
+
mryhkh: '' //默认银行卡号
|
|
250
|
+
};
|
|
251
|
+
|
|
252
|
+
return _this;
|
|
253
|
+
}
|
|
254
|
+
|
|
255
|
+
/**
|
|
256
|
+
* * 自定义表单项渲染
|
|
257
|
+
*
|
|
258
|
+
* @memberof EditInitForm
|
|
259
|
+
*/
|
|
260
|
+
|
|
261
|
+
|
|
262
|
+
_createClass(EditInitForm, [{
|
|
263
|
+
key: "render",
|
|
264
|
+
value: function render() {
|
|
265
|
+
var _props = this.props,
|
|
266
|
+
form = _props.form,
|
|
267
|
+
isEdit = _props.isEdit,
|
|
268
|
+
fieldMap = _props.fieldMap,
|
|
269
|
+
title = _props.title;
|
|
270
|
+
|
|
271
|
+
var dataList = this.getDataList(fieldMap);
|
|
272
|
+
return isEdit ? _react2.default.createElement(
|
|
273
|
+
"form",
|
|
274
|
+
null,
|
|
275
|
+
_react2.default.createElement(
|
|
276
|
+
"style",
|
|
277
|
+
null,
|
|
278
|
+
"\n .am-list-extra{\n -webkit-flex-basis: 50% !important;\n -ms-flex-preferred-size: 50% !important;\n flex-basis: 50% !important;\n }\n "
|
|
279
|
+
),
|
|
280
|
+
_react2.default.createElement(
|
|
281
|
+
_list2.default,
|
|
282
|
+
{ renderHeader: function renderHeader() {
|
|
283
|
+
return title;
|
|
284
|
+
} },
|
|
285
|
+
dataList.filter(function (item, index) {
|
|
286
|
+
return index < 2;
|
|
287
|
+
}).map(function (item) {
|
|
288
|
+
return item.render !== undefined ? item.render() : null;
|
|
289
|
+
})
|
|
290
|
+
),
|
|
291
|
+
dataList && dataList.length >= 2 ? _react2.default.createElement(
|
|
292
|
+
_list2.default,
|
|
293
|
+
{ renderHeader: function renderHeader() {
|
|
294
|
+
return "";
|
|
295
|
+
} },
|
|
296
|
+
dataList.filter(function (item, index) {
|
|
297
|
+
return index >= 2 && index < 5;
|
|
298
|
+
}).map(function (item) {
|
|
299
|
+
return item.render !== undefined ? item.render() : null;
|
|
300
|
+
})
|
|
301
|
+
) : null,
|
|
302
|
+
dataList && dataList.length >= 5 ? _react2.default.createElement(
|
|
303
|
+
_list2.default,
|
|
304
|
+
{ renderHeader: function renderHeader() {
|
|
305
|
+
return "";
|
|
306
|
+
} },
|
|
307
|
+
dataList.filter(function (item, index) {
|
|
308
|
+
return index >= 5 && index < 7;
|
|
309
|
+
}).map(function (item) {
|
|
310
|
+
return item.render !== undefined ? item.render() : null;
|
|
311
|
+
})
|
|
312
|
+
) : null,
|
|
313
|
+
dataList && dataList.length >= 7 ? _react2.default.createElement(
|
|
314
|
+
_list2.default,
|
|
315
|
+
{ renderHeader: function renderHeader() {
|
|
316
|
+
return "";
|
|
317
|
+
} },
|
|
318
|
+
dataList.filter(function (item, index) {
|
|
319
|
+
return index >= 7;
|
|
320
|
+
}).map(function (item) {
|
|
321
|
+
return item.render !== undefined ? item.render() : null;
|
|
322
|
+
})
|
|
323
|
+
) : null,
|
|
324
|
+
_react2.default.createElement(_whiteSpace2.default, { size: "lg" })
|
|
325
|
+
) : _react2.default.createElement(
|
|
326
|
+
"div",
|
|
327
|
+
null,
|
|
328
|
+
_react2.default.createElement(
|
|
329
|
+
_card2.default,
|
|
330
|
+
{ full: true },
|
|
331
|
+
_react2.default.createElement(_card2.default.Header, {
|
|
332
|
+
title: _react2.default.createElement(
|
|
333
|
+
"div",
|
|
334
|
+
{ style: { borderLeft: '3px solid #1890ff', paddingLeft: '10px' } },
|
|
335
|
+
title
|
|
336
|
+
)
|
|
337
|
+
}),
|
|
338
|
+
_react2.default.createElement(
|
|
339
|
+
_card2.default.Body,
|
|
340
|
+
null,
|
|
341
|
+
dataList.map(function (item, index) {
|
|
342
|
+
if (item.isUpload) {
|
|
343
|
+
return _react2.default.createElement(
|
|
344
|
+
"div",
|
|
345
|
+
{ key: index },
|
|
346
|
+
_react2.default.createElement(
|
|
347
|
+
"font",
|
|
348
|
+
{ color: "grey" },
|
|
349
|
+
item.title,
|
|
350
|
+
"\uFF1A "
|
|
351
|
+
),
|
|
352
|
+
item.renderView()
|
|
353
|
+
);
|
|
354
|
+
}
|
|
355
|
+
return _react2.default.createElement(
|
|
356
|
+
"div",
|
|
357
|
+
{ key: index },
|
|
358
|
+
_react2.default.createElement(
|
|
359
|
+
"font",
|
|
360
|
+
{ color: "grey" },
|
|
361
|
+
item.title,
|
|
362
|
+
"\uFF1A "
|
|
363
|
+
),
|
|
364
|
+
item.text,
|
|
365
|
+
_react2.default.createElement("br", null)
|
|
366
|
+
);
|
|
367
|
+
})
|
|
368
|
+
)
|
|
369
|
+
),
|
|
370
|
+
_react2.default.createElement(_whiteSpace2.default, { size: "lg" })
|
|
371
|
+
);
|
|
372
|
+
}
|
|
373
|
+
}]);
|
|
374
|
+
|
|
375
|
+
return EditInitForm;
|
|
376
|
+
}(_react2.default.Component);
|
|
377
|
+
|
|
378
|
+
var EditForm = (0, _rcForm.createForm)()(EditInitForm);
|
|
379
|
+
exports.default = EditForm;
|
|
@@ -0,0 +1,148 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
|
|
7
|
+
var _toast = require('antd-mobile/lib/toast');
|
|
8
|
+
|
|
9
|
+
var _toast2 = _interopRequireDefault(_toast);
|
|
10
|
+
|
|
11
|
+
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; };
|
|
12
|
+
|
|
13
|
+
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; }; }();
|
|
14
|
+
|
|
15
|
+
require('antd-mobile/lib/toast/style/css');
|
|
16
|
+
|
|
17
|
+
var _react = require('react');
|
|
18
|
+
|
|
19
|
+
var _react2 = _interopRequireDefault(_react);
|
|
20
|
+
|
|
21
|
+
var _propTypes = require('prop-types');
|
|
22
|
+
|
|
23
|
+
var _propTypes2 = _interopRequireDefault(_propTypes);
|
|
24
|
+
|
|
25
|
+
var _NHFetch = require('../../../../utils/NHFetch');
|
|
26
|
+
|
|
27
|
+
var _NHFetch2 = _interopRequireDefault(_NHFetch);
|
|
28
|
+
|
|
29
|
+
var _EditForm = require('./EditForm');
|
|
30
|
+
|
|
31
|
+
var _EditForm2 = _interopRequireDefault(_EditForm);
|
|
32
|
+
|
|
33
|
+
var _moment = require('moment');
|
|
34
|
+
|
|
35
|
+
var _moment2 = _interopRequireDefault(_moment);
|
|
36
|
+
|
|
37
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
38
|
+
|
|
39
|
+
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
40
|
+
|
|
41
|
+
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; }
|
|
42
|
+
|
|
43
|
+
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; }
|
|
44
|
+
|
|
45
|
+
/**
|
|
46
|
+
* 请假申请自定义表单
|
|
47
|
+
* @author: zengxiangkai
|
|
48
|
+
* @date: 2020-06-04 16:26:49
|
|
49
|
+
*/
|
|
50
|
+
var WhtlyhkEditForm = function (_React$Component) {
|
|
51
|
+
_inherits(WhtlyhkEditForm, _React$Component);
|
|
52
|
+
|
|
53
|
+
function WhtlyhkEditForm(props) {
|
|
54
|
+
_classCallCheck(this, WhtlyhkEditForm);
|
|
55
|
+
|
|
56
|
+
var _this = _possibleConstructorReturn(this, (WhtlyhkEditForm.__proto__ || Object.getPrototypeOf(WhtlyhkEditForm)).call(this, props));
|
|
57
|
+
|
|
58
|
+
_this.validate = function (func) {
|
|
59
|
+
_this.nhEditForm.validateFields(function (err, formData) {
|
|
60
|
+
if (err) {
|
|
61
|
+
func(false);
|
|
62
|
+
} else {
|
|
63
|
+
_this.setState({ formData: formData }, function () {
|
|
64
|
+
func(true);
|
|
65
|
+
});
|
|
66
|
+
}
|
|
67
|
+
});
|
|
68
|
+
};
|
|
69
|
+
|
|
70
|
+
_this.save = function (func, failCallback) {
|
|
71
|
+
var _this$props = _this.props,
|
|
72
|
+
processApplyId = _this$props.processApplyId,
|
|
73
|
+
objId = _this$props.objId,
|
|
74
|
+
pkid = _this$props.pkid;
|
|
75
|
+
var formData = _this.state.formData;
|
|
76
|
+
|
|
77
|
+
|
|
78
|
+
var yhkh = formData.yhkh;
|
|
79
|
+
var mryhkh = formData.mryhkh;
|
|
80
|
+
if (!yhkh.startsWith(mryhkh)) {
|
|
81
|
+
failCallback && failCallback();
|
|
82
|
+
_toast2.default.fail("银行卡号必须使用农业银行卡号");
|
|
83
|
+
return;
|
|
84
|
+
}
|
|
85
|
+
var param = formData;
|
|
86
|
+
|
|
87
|
+
param.pkid = pkid;
|
|
88
|
+
param.xsid = objId;
|
|
89
|
+
param.lcslid = processApplyId;
|
|
90
|
+
|
|
91
|
+
(0, _NHFetch2.default)('api/sm-student/openapi/saveYhkxx', 'POST', param).then(function (res) {
|
|
92
|
+
if (res && res.code === 200) {
|
|
93
|
+
func();
|
|
94
|
+
} else {
|
|
95
|
+
failCallback && failCallback();
|
|
96
|
+
_toast2.default.fail("保存银行卡信息失败");
|
|
97
|
+
}
|
|
98
|
+
});
|
|
99
|
+
};
|
|
100
|
+
|
|
101
|
+
_this.state = {
|
|
102
|
+
formData: {}
|
|
103
|
+
};
|
|
104
|
+
return _this;
|
|
105
|
+
}
|
|
106
|
+
|
|
107
|
+
/**
|
|
108
|
+
* 校验该分类表单是否全部填写完成,该方法必须存在
|
|
109
|
+
*/
|
|
110
|
+
|
|
111
|
+
|
|
112
|
+
//保存
|
|
113
|
+
|
|
114
|
+
|
|
115
|
+
_createClass(WhtlyhkEditForm, [{
|
|
116
|
+
key: 'render',
|
|
117
|
+
value: function render() {
|
|
118
|
+
var _this2 = this;
|
|
119
|
+
|
|
120
|
+
return _react2.default.createElement(_EditForm2.default, _extends({
|
|
121
|
+
ref: function ref(form) {
|
|
122
|
+
_this2.nhEditForm = form;
|
|
123
|
+
}
|
|
124
|
+
}, this.props));
|
|
125
|
+
}
|
|
126
|
+
}]);
|
|
127
|
+
|
|
128
|
+
return WhtlyhkEditForm;
|
|
129
|
+
}(_react2.default.Component);
|
|
130
|
+
|
|
131
|
+
exports.default = WhtlyhkEditForm;
|
|
132
|
+
|
|
133
|
+
|
|
134
|
+
WhtlyhkEditForm.defaultProps = {
|
|
135
|
+
fieldMap: {},
|
|
136
|
+
params: {}
|
|
137
|
+
};
|
|
138
|
+
|
|
139
|
+
WhtlyhkEditForm.propTypes = {
|
|
140
|
+
pkid: _propTypes2.default.string, //业务表主键ID
|
|
141
|
+
objId: _propTypes2.default.string, //对象ID
|
|
142
|
+
processId: _propTypes2.default.string, //流程ID
|
|
143
|
+
processApplyId: _propTypes2.default.string, //流程申请主键ID
|
|
144
|
+
fieldMap: _propTypes2.default.object, //字段信息,可以通过该对象获取到该字段,是否可以显示(sfxs)、是否可以编辑(sfbj)、是否必填等信息(sfbt)
|
|
145
|
+
params: _propTypes2.default.object, //参数集合,主要通过该参数集合给自定义面板传参
|
|
146
|
+
isEdit: _propTypes2.default.bool, //是否是编辑状态
|
|
147
|
+
title: _propTypes2.default.string
|
|
148
|
+
};
|