ns-base-module 1.0.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.
- package/LICENSE +21 -0
- package/README.md +20 -0
- package/dist/Button/AntdIconButton.d.ts +11 -0
- package/dist/Button/AntdIconButton.d.ts.map +1 -0
- package/dist/Button/AntdIconButton.js +22 -0
- package/dist/Button/ConfigButton.d.ts +18 -0
- package/dist/Button/ConfigButton.d.ts.map +1 -0
- package/dist/Button/ConfigButton.js +78 -0
- package/dist/Button/index.d.ts +8 -0
- package/dist/Button/index.d.ts.map +1 -0
- package/dist/Button/index.js +19 -0
- package/dist/ClassFilter/index.d.ts +11 -0
- package/dist/ClassFilter/index.d.ts.map +1 -0
- package/dist/ClassFilter/index.js +119 -0
- package/dist/ClassFilter/indexVertical.d.ts +10 -0
- package/dist/ClassFilter/indexVertical.d.ts.map +1 -0
- package/dist/ClassFilter/indexVertical.js +69 -0
- package/dist/ClassFilter/util.d.ts +17 -0
- package/dist/ClassFilter/util.d.ts.map +1 -0
- package/dist/ClassFilter/util.js +135 -0
- package/dist/CopyCol/index.d.ts +4 -0
- package/dist/CopyCol/index.d.ts.map +1 -0
- package/dist/CopyCol/index.js +57 -0
- package/dist/Entry/EntryCriteria.d.ts +17 -0
- package/dist/Entry/EntryCriteria.d.ts.map +1 -0
- package/dist/Entry/EntryCriteria.js +138 -0
- package/dist/Entry/EntryItem.d.ts +34 -0
- package/dist/Entry/EntryItem.d.ts.map +1 -0
- package/dist/Entry/EntryItem.js +757 -0
- package/dist/Entry/components/Checkbox.d.ts +12 -0
- package/dist/Entry/components/Checkbox.d.ts.map +1 -0
- package/dist/Entry/components/Checkbox.js +15 -0
- package/dist/Entry/components/ChooseModalTable.d.ts +15 -0
- package/dist/Entry/components/ChooseModalTable.d.ts.map +1 -0
- package/dist/Entry/components/ChooseModalTable.js +407 -0
- package/dist/Entry/components/Condition.d.ts +9 -0
- package/dist/Entry/components/Condition.d.ts.map +1 -0
- package/dist/Entry/components/Condition.js +30 -0
- package/dist/Entry/components/DatePicker.d.ts +12 -0
- package/dist/Entry/components/DatePicker.d.ts.map +1 -0
- package/dist/Entry/components/DatePicker.js +12 -0
- package/dist/Entry/components/Etable2Modal.d.ts +4 -0
- package/dist/Entry/components/Etable2Modal.d.ts.map +1 -0
- package/dist/Entry/components/Etable2Modal.js +122 -0
- package/dist/Entry/components/Express.d.ts +8 -0
- package/dist/Entry/components/Express.d.ts.map +1 -0
- package/dist/Entry/components/Express.js +30 -0
- package/dist/Entry/components/GroupInput.d.ts +13 -0
- package/dist/Entry/components/GroupInput.d.ts.map +1 -0
- package/dist/Entry/components/GroupInput.js +77 -0
- package/dist/Entry/components/ImageText.d.ts +13 -0
- package/dist/Entry/components/ImageText.d.ts.map +1 -0
- package/dist/Entry/components/ImageText.js +235 -0
- package/dist/Entry/components/Input.d.ts +27 -0
- package/dist/Entry/components/Input.d.ts.map +1 -0
- package/dist/Entry/components/Input.js +86 -0
- package/dist/Entry/components/InputNumber.d.ts +18 -0
- package/dist/Entry/components/InputNumber.d.ts.map +1 -0
- package/dist/Entry/components/InputNumber.js +111 -0
- package/dist/Entry/components/InputNumberRange.d.ts +10 -0
- package/dist/Entry/components/InputNumberRange.d.ts.map +1 -0
- package/dist/Entry/components/InputNumberRange.js +58 -0
- package/dist/Entry/components/ListSelect.d.ts +15 -0
- package/dist/Entry/components/ListSelect.d.ts.map +1 -0
- package/dist/Entry/components/ListSelect.js +110 -0
- package/dist/Entry/components/ObjectSelect.d.ts +14 -0
- package/dist/Entry/components/ObjectSelect.d.ts.map +1 -0
- package/dist/Entry/components/ObjectSelect.js +91 -0
- package/dist/Entry/components/Progress.d.ts +11 -0
- package/dist/Entry/components/Progress.d.ts.map +1 -0
- package/dist/Entry/components/Progress.js +63 -0
- package/dist/Entry/components/Radio.d.ts +15 -0
- package/dist/Entry/components/Radio.d.ts.map +1 -0
- package/dist/Entry/components/Radio.js +17 -0
- package/dist/Entry/components/Select.d.ts +29 -0
- package/dist/Entry/components/Select.d.ts.map +1 -0
- package/dist/Entry/components/Select.js +113 -0
- package/dist/Entry/components/Switch.d.ts +6 -0
- package/dist/Entry/components/Switch.d.ts.map +1 -0
- package/dist/Entry/components/Switch.js +19 -0
- package/dist/Entry/components/TagsDatePicker.d.ts +7 -0
- package/dist/Entry/components/TagsDatePicker.d.ts.map +1 -0
- package/dist/Entry/components/TagsDatePicker.js +229 -0
- package/dist/Entry/components/TimePicker.d.ts +6 -0
- package/dist/Entry/components/TimePicker.d.ts.map +1 -0
- package/dist/Entry/components/TimePicker.js +6 -0
- package/dist/Entry/components/TreeSelect.d.ts +6 -0
- package/dist/Entry/components/TreeSelect.d.ts.map +1 -0
- package/dist/Entry/components/TreeSelect.js +18 -0
- package/dist/Entry/components/index.scss +97 -0
- package/dist/Entry/components/utils.d.ts +1 -0
- package/dist/Entry/components/utils.d.ts.map +1 -0
- package/dist/Entry/components/utils.js +6 -0
- package/dist/Entry/data.d.ts +133 -0
- package/dist/Entry/index.d.ts +54 -0
- package/dist/Entry/index.d.ts.map +1 -0
- package/dist/Entry/index.js +45 -0
- package/dist/FilterPopover/Filter.d.ts +24 -0
- package/dist/FilterPopover/Filter.d.ts.map +1 -0
- package/dist/FilterPopover/Filter.js +370 -0
- package/dist/FilterPopover/FilterClearIcon.d.ts +8 -0
- package/dist/FilterPopover/FilterClearIcon.d.ts.map +1 -0
- package/dist/FilterPopover/FilterClearIcon.js +45 -0
- package/dist/FilterPopover/index.d.ts +20 -0
- package/dist/FilterPopover/index.d.ts.map +1 -0
- package/dist/FilterPopover/index.js +136 -0
- package/dist/Icon/IconCreate.d.ts +11 -0
- package/dist/Icon/IconCreate.d.ts.map +1 -0
- package/dist/Icon/IconCreate.js +22 -0
- package/dist/Icon/index.d.ts +6 -0
- package/dist/Icon/index.d.ts.map +1 -0
- package/dist/Icon/index.js +22 -0
- package/dist/WidgetConfig/index.d.ts +40 -0
- package/dist/WidgetConfig/index.d.ts.map +1 -0
- package/dist/WidgetConfig/index.js +129 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +4 -0
- package/dist/test/index.d.ts +4 -0
- package/dist/test/index.d.ts.map +1 -0
- package/dist/test/index.js +7 -0
- package/dist/umd/ns-base-module.min.js +1 -0
- package/dist/utils/cache.d.ts +17 -0
- package/dist/utils/cache.d.ts.map +1 -0
- package/dist/utils/cache.js +127 -0
- package/dist/utils/enum.d.ts +22 -0
- package/dist/utils/enum.d.ts.map +1 -0
- package/dist/utils/enum.js +37 -0
- package/dist/utils/language.d.ts +241 -0
- package/dist/utils/language.d.ts.map +1 -0
- package/dist/utils/language.js +247 -0
- package/dist/utils/request.d.ts +15 -0
- package/dist/utils/request.d.ts.map +1 -0
- package/dist/utils/request.js +180 -0
- package/dist/utils/utils.d.ts +113 -0
- package/dist/utils/utils.d.ts.map +1 -0
- package/dist/utils/utils.js +462 -0
- package/package.json +97 -0
- package/style/basics.scss +671 -0
- package/style/components/ClassFilter.scss +69 -0
- package/style/components/FilterPopover.scss +34 -0
- package/style/components/index.scss +2 -0
- package/style/default.scss +1219 -0
- package/style/index.scss +1 -0
- package/style/mixins/index.scss +28 -0
- package/style/mixins/libs/tint.scss +23 -0
- package/style/variables.scss +684 -0
- package/types/Action.d.ts +43 -0
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import type { CheckboxProps } from 'antd';
|
|
3
|
+
import type { CheckboxGroupProps } from 'antd/lib/checkbox';
|
|
4
|
+
declare const Group: (props: CheckboxGroupProps) => React.JSX.Element;
|
|
5
|
+
declare const index: {
|
|
6
|
+
(props: CheckboxProps): React.JSX.Element;
|
|
7
|
+
Group: (props: CheckboxGroupProps) => React.JSX.Element;
|
|
8
|
+
};
|
|
9
|
+
export default index;
|
|
10
|
+
export type { Group };
|
|
11
|
+
export type { CheckboxProps, CheckboxGroupProps };
|
|
12
|
+
//# sourceMappingURL=Checkbox.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Checkbox.d.ts","sourceRoot":"","sources":["Checkbox.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAI1B,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,MAAM,CAAC;AAC1C,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,mBAAmB,CAAC;AAI5D,QAAA,MAAM,KAAK,UAAW,kBAAkB,sBAEvC,CAAC;AAEF,QAAA,MAAM,KAAK;YAAW,aAAa;mBAJb,kBAAkB;CAMvC,CAAC;AAIF,eAAe,KAAK,CAAC;AAErB,YAAY,EAAE,KAAK,EAAE,CAAC;AACtB,YAAY,EAAE,aAAa,EAAE,kBAAkB,EAAE,CAAC"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
function _extends() { _extends = Object.assign ? Object.assign.bind() : 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; }; return _extends.apply(this, arguments); }
|
|
2
|
+
import React from 'react';
|
|
3
|
+
import { get } from 'lodash';
|
|
4
|
+
import { Checkbox } from 'antd';
|
|
5
|
+
var CheckboxGroup = Checkbox.Group;
|
|
6
|
+
var Group = function Group(props) {
|
|
7
|
+
return /*#__PURE__*/React.createElement(CheckboxGroup, _extends({}, props, {
|
|
8
|
+
className: get(props, "optionType", null) === "button" ? 'custom-checkbox-group' : props.className
|
|
9
|
+
}));
|
|
10
|
+
};
|
|
11
|
+
var index = function index(props) {
|
|
12
|
+
return /*#__PURE__*/React.createElement(Checkbox, props);
|
|
13
|
+
};
|
|
14
|
+
index.Group = Group;
|
|
15
|
+
export default index;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import type { ChooseModalProps } from '@/components/v2/Modal';
|
|
3
|
+
interface ListSelectProps extends ChooseModalProps {
|
|
4
|
+
value?: string;
|
|
5
|
+
onChange?: (e: React.ChangeEvent<HTMLInputElement>) => void;
|
|
6
|
+
style?: React.CSSProperties;
|
|
7
|
+
className?: string;
|
|
8
|
+
params?: Record<string, any>;
|
|
9
|
+
disabled?: boolean;
|
|
10
|
+
clearForm?: () => void;
|
|
11
|
+
templateName?: string;
|
|
12
|
+
}
|
|
13
|
+
declare const ListSelect: React.FC<ListSelectProps>;
|
|
14
|
+
export default ListSelect;
|
|
15
|
+
//# sourceMappingURL=ChooseModalTable.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ChooseModalTable.d.ts","sourceRoot":"","sources":["ChooseModalTable.tsx"],"names":[],"mappings":"AAOA,OAAO,KAA+C,MAAM,OAAO,CAAC;AAEpE,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,uBAAuB,CAAC;AAuW9D,UAAU,eAAgB,SAAQ,gBAAgB;IAChD,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,QAAQ,CAAC,EAAE,CAAC,CAAC,EAAE,KAAK,CAAC,WAAW,CAAC,gBAAgB,CAAC,KAAK,IAAI,CAAC;IAC5D,KAAK,CAAC,EAAE,KAAK,CAAC,aAAa,CAAC;IAC5B,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,MAAM,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;IAC7B,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,SAAS,CAAC,EAAE,MAAM,IAAI,CAAC;IACvB,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB;AAED,QAAA,MAAM,UAAU,EAAE,KAAK,CAAC,EAAE,CAAC,eAAe,CAmHzC,CAAC;AAEF,eAAe,UAAU,CAAC"}
|
|
@@ -0,0 +1,407 @@
|
|
|
1
|
+
function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
|
|
2
|
+
var _excluded = ["style", "className", "value", "onChange", "menuCode", "formTemplateCode", "onSelectSubmit", "clearForm", "params", "disabled", "templateName"];
|
|
3
|
+
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
4
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
5
|
+
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
6
|
+
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
|
|
7
|
+
function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
8
|
+
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
9
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
10
|
+
/*
|
|
11
|
+
* @Date: 2023-05-08 13:49:29
|
|
12
|
+
* @description:
|
|
13
|
+
* @author chenchangfu
|
|
14
|
+
* Copyright (c) 2019, AUTHOR. All rights reserved.
|
|
15
|
+
* AUTHOR PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
|
|
16
|
+
*/
|
|
17
|
+
import React, { useRef } from 'react';
|
|
18
|
+
import { ETable2 } from '@/components/v2/Table';
|
|
19
|
+
var _config = {
|
|
20
|
+
type: 'ETABLE2',
|
|
21
|
+
formType: null,
|
|
22
|
+
code: 'fab',
|
|
23
|
+
label: '材料',
|
|
24
|
+
relationCode: null,
|
|
25
|
+
tableName: null,
|
|
26
|
+
relationField: null,
|
|
27
|
+
mappingField: null,
|
|
28
|
+
filterFieldGroups: [],
|
|
29
|
+
showSelect: null,
|
|
30
|
+
crossor: null,
|
|
31
|
+
children: [],
|
|
32
|
+
childrenItems: [],
|
|
33
|
+
colSpan: 24,
|
|
34
|
+
buttons: null,
|
|
35
|
+
renderRelationCode: null,
|
|
36
|
+
renderRelationValues: null,
|
|
37
|
+
collapse: null,
|
|
38
|
+
childrenFields: [],
|
|
39
|
+
queryType: null,
|
|
40
|
+
express: null,
|
|
41
|
+
formTemplateCode: 'pdBomTplDetailEdit',
|
|
42
|
+
menuFormConfigs: {
|
|
43
|
+
formTemplateCode: 'pdBomTplDetailEdit',
|
|
44
|
+
formTemplateName: 'BOM模板-材料明细编辑',
|
|
45
|
+
formTemplateType: 'ETABLE2',
|
|
46
|
+
formTemplateRemark: '',
|
|
47
|
+
modifiedTime: 1712570785000,
|
|
48
|
+
clearCacheTime: 1712570785000,
|
|
49
|
+
helpDocument: '',
|
|
50
|
+
layout: 'horizontal',
|
|
51
|
+
favoriteStatus: false,
|
|
52
|
+
favoriteApi: '/dataProcess/commonSave/favoriteList/favoriteCreate/createSave',
|
|
53
|
+
buttons: [{
|
|
54
|
+
code: 'batchAddETABLE2',
|
|
55
|
+
type: 'primary',
|
|
56
|
+
group: 'common',
|
|
57
|
+
formTemplateCode: 'pdBom2FabMstSelect',
|
|
58
|
+
searchFormConfigs: null,
|
|
59
|
+
fieldCode: null,
|
|
60
|
+
entryType: null,
|
|
61
|
+
config: {
|
|
62
|
+
code: null,
|
|
63
|
+
name: '批量增加',
|
|
64
|
+
type: 'BC',
|
|
65
|
+
callback: null,
|
|
66
|
+
requestMethod: 'POST',
|
|
67
|
+
path: null,
|
|
68
|
+
redirect: null,
|
|
69
|
+
style: null,
|
|
70
|
+
event: null,
|
|
71
|
+
min: 0,
|
|
72
|
+
max: 0,
|
|
73
|
+
requiredValidate: null,
|
|
74
|
+
operType: null,
|
|
75
|
+
icon: 'PlusSquareOutlined',
|
|
76
|
+
auth: true,
|
|
77
|
+
desc: null,
|
|
78
|
+
styles: {},
|
|
79
|
+
tableEdit: false,
|
|
80
|
+
modalType: null,
|
|
81
|
+
modalWidth: null,
|
|
82
|
+
showExpression: null,
|
|
83
|
+
addSite: null,
|
|
84
|
+
dataProcessInterceptors: []
|
|
85
|
+
}
|
|
86
|
+
}],
|
|
87
|
+
uiLang: null,
|
|
88
|
+
listFields: [{
|
|
89
|
+
primaryKey: false,
|
|
90
|
+
code: 'comp_code',
|
|
91
|
+
editable: true,
|
|
92
|
+
visitable: true,
|
|
93
|
+
defaultDisplay: true,
|
|
94
|
+
entryType: 'Input',
|
|
95
|
+
dataType: 'string',
|
|
96
|
+
colSpan: 8,
|
|
97
|
+
label: '组件编码',
|
|
98
|
+
description: null,
|
|
99
|
+
generateRule: '',
|
|
100
|
+
dict: null,
|
|
101
|
+
dictItems: [],
|
|
102
|
+
validateRule: '',
|
|
103
|
+
validateTips: null,
|
|
104
|
+
width: 120,
|
|
105
|
+
align: 'center',
|
|
106
|
+
height: null,
|
|
107
|
+
jsonField: 'para_val',
|
|
108
|
+
ellipsis: false,
|
|
109
|
+
defaultValue: '',
|
|
110
|
+
generatorValue: null,
|
|
111
|
+
required: false,
|
|
112
|
+
entryAttr: {
|
|
113
|
+
chooseFields: ['comp_code', 'comp_name', 'category', 'color', 'color_name'],
|
|
114
|
+
formTemplateCode: 'mmFabMaterialSelectList'
|
|
115
|
+
},
|
|
116
|
+
criteriaType: null,
|
|
117
|
+
criteriaTypeItems: null,
|
|
118
|
+
mobileCriteriaType: 'Equals',
|
|
119
|
+
summaryType: null,
|
|
120
|
+
renderEntryType: null,
|
|
121
|
+
renderEntryAttr: {},
|
|
122
|
+
styles: {},
|
|
123
|
+
parentCode: null,
|
|
124
|
+
headerStyle: {},
|
|
125
|
+
isSort: false,
|
|
126
|
+
sortType: 'asc',
|
|
127
|
+
mappingCode: null,
|
|
128
|
+
suffix: '',
|
|
129
|
+
prefix: '',
|
|
130
|
+
changeLog: null,
|
|
131
|
+
dataFormat: null,
|
|
132
|
+
crossTabFieldType: null,
|
|
133
|
+
renderRelationCode: null,
|
|
134
|
+
renderRelationValues: null,
|
|
135
|
+
children: null,
|
|
136
|
+
frontProperties: null,
|
|
137
|
+
rowIndex: null,
|
|
138
|
+
colIndex: null,
|
|
139
|
+
cs: null,
|
|
140
|
+
batchSetVal: false,
|
|
141
|
+
disabled: false,
|
|
142
|
+
fixed: 'left',
|
|
143
|
+
requiredRules: null,
|
|
144
|
+
visitableRules: null,
|
|
145
|
+
emit: null,
|
|
146
|
+
copiable: false,
|
|
147
|
+
mergeCol: null,
|
|
148
|
+
editRule: null,
|
|
149
|
+
importField: true,
|
|
150
|
+
frontComputeExp: null,
|
|
151
|
+
editTableSort: false,
|
|
152
|
+
sortabledKey: null,
|
|
153
|
+
timeType: false,
|
|
154
|
+
imageField: false,
|
|
155
|
+
stepsEntry: false,
|
|
156
|
+
entryAttrFormTemplateCode: null,
|
|
157
|
+
defCriteriaType: 'Contains',
|
|
158
|
+
transferDataEntry: false,
|
|
159
|
+
reverseTransferDataEntry: true,
|
|
160
|
+
unixTimeType: false,
|
|
161
|
+
summaryField: false,
|
|
162
|
+
tableField: true,
|
|
163
|
+
noneSave: false
|
|
164
|
+
}, {
|
|
165
|
+
primaryKey: false,
|
|
166
|
+
code: 'comp_name',
|
|
167
|
+
editable: true,
|
|
168
|
+
visitable: true,
|
|
169
|
+
defaultDisplay: true,
|
|
170
|
+
entryType: 'Input',
|
|
171
|
+
dataType: 'string',
|
|
172
|
+
colSpan: 8,
|
|
173
|
+
label: '组件名称',
|
|
174
|
+
description: null,
|
|
175
|
+
generateRule: '',
|
|
176
|
+
dict: null,
|
|
177
|
+
dictItems: [],
|
|
178
|
+
validateRule: '',
|
|
179
|
+
validateTips: null,
|
|
180
|
+
width: 150,
|
|
181
|
+
align: 'center',
|
|
182
|
+
height: null,
|
|
183
|
+
jsonField: 'para_val',
|
|
184
|
+
ellipsis: false,
|
|
185
|
+
defaultValue: '',
|
|
186
|
+
generatorValue: null,
|
|
187
|
+
required: false,
|
|
188
|
+
entryAttr: {},
|
|
189
|
+
criteriaType: null,
|
|
190
|
+
criteriaTypeItems: null,
|
|
191
|
+
mobileCriteriaType: 'Equals',
|
|
192
|
+
summaryType: null,
|
|
193
|
+
renderEntryType: null,
|
|
194
|
+
renderEntryAttr: {},
|
|
195
|
+
styles: {},
|
|
196
|
+
parentCode: null,
|
|
197
|
+
headerStyle: {},
|
|
198
|
+
isSort: false,
|
|
199
|
+
sortType: 'asc',
|
|
200
|
+
mappingCode: null,
|
|
201
|
+
suffix: '',
|
|
202
|
+
prefix: '',
|
|
203
|
+
changeLog: null,
|
|
204
|
+
dataFormat: null,
|
|
205
|
+
crossTabFieldType: null,
|
|
206
|
+
renderRelationCode: null,
|
|
207
|
+
renderRelationValues: null,
|
|
208
|
+
children: null,
|
|
209
|
+
frontProperties: null,
|
|
210
|
+
rowIndex: null,
|
|
211
|
+
colIndex: null,
|
|
212
|
+
cs: null,
|
|
213
|
+
batchSetVal: false,
|
|
214
|
+
disabled: true,
|
|
215
|
+
fixed: null,
|
|
216
|
+
requiredRules: null,
|
|
217
|
+
visitableRules: null,
|
|
218
|
+
emit: null,
|
|
219
|
+
copiable: false,
|
|
220
|
+
mergeCol: null,
|
|
221
|
+
editRule: null,
|
|
222
|
+
importField: true,
|
|
223
|
+
frontComputeExp: null,
|
|
224
|
+
editTableSort: false,
|
|
225
|
+
sortabledKey: null,
|
|
226
|
+
timeType: false,
|
|
227
|
+
imageField: false,
|
|
228
|
+
stepsEntry: false,
|
|
229
|
+
entryAttrFormTemplateCode: null,
|
|
230
|
+
defCriteriaType: 'Contains',
|
|
231
|
+
transferDataEntry: false,
|
|
232
|
+
reverseTransferDataEntry: true,
|
|
233
|
+
unixTimeType: false,
|
|
234
|
+
summaryField: false,
|
|
235
|
+
tableField: true,
|
|
236
|
+
noneSave: false
|
|
237
|
+
}, {
|
|
238
|
+
primaryKey: false,
|
|
239
|
+
code: 'position',
|
|
240
|
+
editable: true,
|
|
241
|
+
visitable: true,
|
|
242
|
+
defaultDisplay: true,
|
|
243
|
+
entryType: 'Textarea',
|
|
244
|
+
dataType: 'string',
|
|
245
|
+
colSpan: 8,
|
|
246
|
+
label: '使用部位',
|
|
247
|
+
description: null,
|
|
248
|
+
generateRule: '',
|
|
249
|
+
dict: null,
|
|
250
|
+
dictItems: [],
|
|
251
|
+
validateRule: '',
|
|
252
|
+
validateTips: null,
|
|
253
|
+
width: 150,
|
|
254
|
+
align: 'center',
|
|
255
|
+
height: null,
|
|
256
|
+
jsonField: 'para_val',
|
|
257
|
+
ellipsis: false,
|
|
258
|
+
defaultValue: '',
|
|
259
|
+
generatorValue: null,
|
|
260
|
+
required: false,
|
|
261
|
+
entryAttr: {},
|
|
262
|
+
criteriaType: null,
|
|
263
|
+
criteriaTypeItems: [{
|
|
264
|
+
value: 'In',
|
|
265
|
+
label: '包含'
|
|
266
|
+
}, {
|
|
267
|
+
value: 'NotIn',
|
|
268
|
+
label: '不包含'
|
|
269
|
+
}, {
|
|
270
|
+
value: 'IsNull',
|
|
271
|
+
label: '空'
|
|
272
|
+
}],
|
|
273
|
+
mobileCriteriaType: 'Equals',
|
|
274
|
+
summaryType: null,
|
|
275
|
+
renderEntryType: null,
|
|
276
|
+
renderEntryAttr: {},
|
|
277
|
+
styles: {},
|
|
278
|
+
parentCode: null,
|
|
279
|
+
headerStyle: {},
|
|
280
|
+
isSort: false,
|
|
281
|
+
sortType: 'asc',
|
|
282
|
+
mappingCode: null,
|
|
283
|
+
suffix: '',
|
|
284
|
+
prefix: '',
|
|
285
|
+
changeLog: null,
|
|
286
|
+
dataFormat: null,
|
|
287
|
+
crossTabFieldType: null,
|
|
288
|
+
renderRelationCode: null,
|
|
289
|
+
renderRelationValues: null,
|
|
290
|
+
children: null,
|
|
291
|
+
frontProperties: null,
|
|
292
|
+
rowIndex: null,
|
|
293
|
+
colIndex: null,
|
|
294
|
+
cs: null,
|
|
295
|
+
batchSetVal: false,
|
|
296
|
+
disabled: true,
|
|
297
|
+
fixed: null,
|
|
298
|
+
requiredRules: null,
|
|
299
|
+
visitableRules: null,
|
|
300
|
+
emit: null,
|
|
301
|
+
copiable: false,
|
|
302
|
+
mergeCol: null,
|
|
303
|
+
editRule: null,
|
|
304
|
+
importField: true,
|
|
305
|
+
frontComputeExp: null,
|
|
306
|
+
editTableSort: false,
|
|
307
|
+
sortabledKey: null,
|
|
308
|
+
timeType: false,
|
|
309
|
+
imageField: false,
|
|
310
|
+
stepsEntry: false,
|
|
311
|
+
entryAttrFormTemplateCode: null,
|
|
312
|
+
defCriteriaType: 'In',
|
|
313
|
+
transferDataEntry: false,
|
|
314
|
+
reverseTransferDataEntry: false,
|
|
315
|
+
unixTimeType: false,
|
|
316
|
+
summaryField: false,
|
|
317
|
+
tableField: true,
|
|
318
|
+
noneSave: false
|
|
319
|
+
}],
|
|
320
|
+
filterFieldGroups: null,
|
|
321
|
+
cardFieldGroups: null,
|
|
322
|
+
firstLevelFieldGroups: null,
|
|
323
|
+
firstLevelBottomFieldGroups: null,
|
|
324
|
+
cardConfigs: null,
|
|
325
|
+
radioSelect: false,
|
|
326
|
+
firstLoad: null,
|
|
327
|
+
pagination: true,
|
|
328
|
+
maxRow: null,
|
|
329
|
+
isHideSearchBtn: false,
|
|
330
|
+
isShowSelect: false,
|
|
331
|
+
colSpan: 2,
|
|
332
|
+
cardColSpan: null,
|
|
333
|
+
showType: null,
|
|
334
|
+
arguments: null,
|
|
335
|
+
height: null,
|
|
336
|
+
sortabled: true,
|
|
337
|
+
globalSortable: null,
|
|
338
|
+
insertTable: null,
|
|
339
|
+
pageSize: null,
|
|
340
|
+
subtotalStyles: {},
|
|
341
|
+
totalStyles: {},
|
|
342
|
+
searchShowType: null,
|
|
343
|
+
matchRowCode: null,
|
|
344
|
+
countCode: null,
|
|
345
|
+
imageCode: null,
|
|
346
|
+
labelCode: null,
|
|
347
|
+
pathCode: null,
|
|
348
|
+
width: 60,
|
|
349
|
+
background: null
|
|
350
|
+
},
|
|
351
|
+
relationable: null,
|
|
352
|
+
chooseFormTemplateCode: null,
|
|
353
|
+
chooseFields: null,
|
|
354
|
+
chooseRelationCode: null,
|
|
355
|
+
modalFormTemplateCode: null,
|
|
356
|
+
inputModalFormTemplateCode: null,
|
|
357
|
+
inputModalField: null,
|
|
358
|
+
inputModalPlaceholder: null,
|
|
359
|
+
primaryKeyFieldConfigs: [],
|
|
360
|
+
formTypeByItemType: 'ETABLE2',
|
|
361
|
+
formTableItem: true
|
|
362
|
+
};
|
|
363
|
+
var ListSelect = function ListSelect(_ref) {
|
|
364
|
+
var style = _ref.style,
|
|
365
|
+
className = _ref.className,
|
|
366
|
+
value = _ref.value,
|
|
367
|
+
onChange = _ref.onChange,
|
|
368
|
+
menuCode = _ref.menuCode,
|
|
369
|
+
formTemplateCode = _ref.formTemplateCode,
|
|
370
|
+
onSelectSubmit = _ref.onSelectSubmit,
|
|
371
|
+
clearForm = _ref.clearForm,
|
|
372
|
+
params = _ref.params,
|
|
373
|
+
disabled = _ref.disabled,
|
|
374
|
+
templateName = _ref.templateName,
|
|
375
|
+
props = _objectWithoutProperties(_ref, _excluded);
|
|
376
|
+
var chooseModalRef = useRef();
|
|
377
|
+
var handleInput = function handleInput() {
|
|
378
|
+
var _chooseModalRef$curre;
|
|
379
|
+
if (disabled) return;
|
|
380
|
+
(_chooseModalRef$curre = chooseModalRef.current) === null || _chooseModalRef$curre === void 0 || _chooseModalRef$curre.onShow();
|
|
381
|
+
};
|
|
382
|
+
var handleClear = function handleClear() {
|
|
383
|
+
clearForm === null || clearForm === void 0 || clearForm();
|
|
384
|
+
};
|
|
385
|
+
return /*#__PURE__*/React.createElement("div", {
|
|
386
|
+
style: _objectSpread({
|
|
387
|
+
position: 'relative'
|
|
388
|
+
}, style),
|
|
389
|
+
className: className
|
|
390
|
+
}, /*#__PURE__*/React.createElement(ETable2, {
|
|
391
|
+
menuCode: menuCode || '',
|
|
392
|
+
config: JSON.stringify(_config.menuFormConfigs),
|
|
393
|
+
value: []
|
|
394
|
+
// value={values[item.code] || []}
|
|
395
|
+
// variablePara={{
|
|
396
|
+
// ..._params,
|
|
397
|
+
// ...(item.relationCode
|
|
398
|
+
// ? { [item.relationCode]: values[item.relationCode] }
|
|
399
|
+
// : {}),
|
|
400
|
+
// }}
|
|
401
|
+
// onChange={(nextValues) => onChangeValues?.(item.code, nextValues)}
|
|
402
|
+
// onJump={onJump}
|
|
403
|
+
// onOpen={onOpen}
|
|
404
|
+
// onSelectedRows={onSelectedRows}
|
|
405
|
+
}));
|
|
406
|
+
};
|
|
407
|
+
export default ListSelect;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { TagConditionEnum } from '@/utils/enum';
|
|
3
|
+
interface ConditionProps {
|
|
4
|
+
dataType?: 'String' | 'Number';
|
|
5
|
+
type?: TagConditionEnum;
|
|
6
|
+
}
|
|
7
|
+
declare const Condition: React.FC<ConditionProps>;
|
|
8
|
+
export default Condition;
|
|
9
|
+
//# sourceMappingURL=Condition.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Condition.d.ts","sourceRoot":"","sources":["Condition.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,gBAAgB,EAAE,MAAM,cAAc,CAAC;AAIhD,UAAU,cAAc;IACtB,QAAQ,CAAC,EAAE,QAAQ,GAAG,QAAQ,CAAC;IAC/B,IAAI,CAAC,EAAE,gBAAgB,CAAC;CACzB;AAED,QAAA,MAAM,SAAS,EAAE,KAAK,CAAC,EAAE,CAAC,cAAc,CAqBvC,CAAC;AAEF,eAAe,SAAS,CAAC"}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
var _excluded = ["dataType", "type"];
|
|
2
|
+
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
3
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
4
|
+
import React from 'react';
|
|
5
|
+
import { TagConditionEnum } from '@/utils/enum';
|
|
6
|
+
import Input from "./Input";
|
|
7
|
+
import InputNumber from "./InputNumber";
|
|
8
|
+
var Condition = function Condition(_ref) {
|
|
9
|
+
var dataType = _ref.dataType,
|
|
10
|
+
_ref$type = _ref.type,
|
|
11
|
+
type = _ref$type === void 0 ? TagConditionEnum.Equals : _ref$type,
|
|
12
|
+
props = _objectWithoutProperties(_ref, _excluded);
|
|
13
|
+
// console.log(dataType);
|
|
14
|
+
var render = function render() {
|
|
15
|
+
switch (type) {
|
|
16
|
+
case TagConditionEnum.Equals:
|
|
17
|
+
case TagConditionEnum.NotEqual:
|
|
18
|
+
case TagConditionEnum.LessThan:
|
|
19
|
+
case TagConditionEnum.LessOrEqual:
|
|
20
|
+
case TagConditionEnum.GreaterThan:
|
|
21
|
+
case TagConditionEnum.GreaterOrEqual:
|
|
22
|
+
case TagConditionEnum.Contains:
|
|
23
|
+
return dataType == 'String' ? /*#__PURE__*/React.createElement(Input, props) : /*#__PURE__*/React.createElement(InputNumber, props);
|
|
24
|
+
default:
|
|
25
|
+
return /*#__PURE__*/React.createElement("div", null);
|
|
26
|
+
}
|
|
27
|
+
};
|
|
28
|
+
return render();
|
|
29
|
+
};
|
|
30
|
+
export default Condition;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import type { DatePickerProps } from 'antd';
|
|
3
|
+
import type { RangePickerProps } from 'antd/lib/date-picker';
|
|
4
|
+
declare const DatePickerWrapper: {
|
|
5
|
+
(props: DatePickerProps): React.JSX.Element;
|
|
6
|
+
RangePicker: (props: RangePickerProps) => React.JSX.Element;
|
|
7
|
+
};
|
|
8
|
+
declare const RangePicker: (props: RangePickerProps) => React.JSX.Element;
|
|
9
|
+
export default DatePickerWrapper;
|
|
10
|
+
export { RangePicker };
|
|
11
|
+
export type { RangePickerProps, DatePickerProps };
|
|
12
|
+
//# sourceMappingURL=DatePicker.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"DatePicker.d.ts","sourceRoot":"","sources":["DatePicker.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,MAAM,CAAC;AAG5C,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,sBAAsB,CAAC;AAI7D,QAAA,MAAM,iBAAiB;YAAW,eAAe;yBAIrB,gBAAgB;CAF3C,CAAC;AAEF,QAAA,MAAM,WAAW,UAAW,gBAAgB,sBAE3C,CAAC;AAIF,eAAe,iBAAiB,CAAC;AAEjC,OAAO,EAAE,WAAW,EAAE,CAAC;AAEvB,YAAY,EAAE,gBAAgB,EAAE,eAAe,EAAE,CAAC"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { DatePicker } from 'antd';
|
|
3
|
+
var Range = DatePicker.RangePicker;
|
|
4
|
+
var DatePickerWrapper = function DatePickerWrapper(props) {
|
|
5
|
+
return /*#__PURE__*/React.createElement(DatePicker, props);
|
|
6
|
+
};
|
|
7
|
+
var RangePicker = function RangePicker(props) {
|
|
8
|
+
return /*#__PURE__*/React.createElement(Range, props);
|
|
9
|
+
};
|
|
10
|
+
DatePickerWrapper.RangePicker = RangePicker;
|
|
11
|
+
export default DatePickerWrapper;
|
|
12
|
+
export { RangePicker };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Etable2Modal.d.ts","sourceRoot":"","sources":["Etable2Modal.tsx"],"names":[],"mappings":"AA+GA,wBAAgB,SAAS,CAAC,GAAG,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,EAAE,EAAE,SAAS,SAAM,EAAE,UAAU,SAAM,UAYtF;;AAED,wBAAgC"}
|
|
@@ -0,0 +1,122 @@
|
|
|
1
|
+
var _excluded = ["value", "onChange", "formTemplateCode", "dispatch", "disabled", "menuCode", "fontSplit", "groupSplit"];
|
|
2
|
+
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
3
|
+
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
4
|
+
function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
|
|
5
|
+
function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
|
|
6
|
+
function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
|
|
7
|
+
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
8
|
+
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
9
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
10
|
+
import React, { useEffect, useState } from 'react';
|
|
11
|
+
import Button from '@/components/Button';
|
|
12
|
+
import { ChooseModal } from '@/components/v2/Modal';
|
|
13
|
+
import { ETable2 } from '@/components/v2/Table';
|
|
14
|
+
import { connect } from 'umi';
|
|
15
|
+
var Index = function Index(props) {
|
|
16
|
+
var value = props.value,
|
|
17
|
+
onChange = props.onChange,
|
|
18
|
+
formTemplateCode = props.formTemplateCode,
|
|
19
|
+
dispatch = props.dispatch,
|
|
20
|
+
_props$disabled = props.disabled,
|
|
21
|
+
disabled = _props$disabled === void 0 ? false : _props$disabled,
|
|
22
|
+
menuCode = props.menuCode,
|
|
23
|
+
_props$fontSplit = props.fontSplit,
|
|
24
|
+
fontSplit = _props$fontSplit === void 0 ? ',' : _props$fontSplit,
|
|
25
|
+
_props$groupSplit = props.groupSplit,
|
|
26
|
+
groupSplit = _props$groupSplit === void 0 ? ';' : _props$groupSplit,
|
|
27
|
+
arg = _objectWithoutProperties(props, _excluded);
|
|
28
|
+
var _useState = useState(false),
|
|
29
|
+
_useState2 = _slicedToArray(_useState, 2),
|
|
30
|
+
visible = _useState2[0],
|
|
31
|
+
setVisible = _useState2[1];
|
|
32
|
+
var _useState3 = useState({}),
|
|
33
|
+
_useState4 = _slicedToArray(_useState3, 2),
|
|
34
|
+
config = _useState4[0],
|
|
35
|
+
setConfig = _useState4[1];
|
|
36
|
+
var _useState5 = useState(value),
|
|
37
|
+
_useState6 = _slicedToArray(_useState5, 2),
|
|
38
|
+
dataSource = _useState6[0],
|
|
39
|
+
setDataSource = _useState6[1];
|
|
40
|
+
useEffect(function () {
|
|
41
|
+
if (visible) {
|
|
42
|
+
setDataSource(value);
|
|
43
|
+
}
|
|
44
|
+
}, [value, visible]);
|
|
45
|
+
var getConfig = function getConfig() {
|
|
46
|
+
if (!formTemplateCode) return;
|
|
47
|
+
dispatch({
|
|
48
|
+
type: 'list/fetchModalConfig',
|
|
49
|
+
payload: {
|
|
50
|
+
menuCode: menuCode,
|
|
51
|
+
formTemplateCode: formTemplateCode
|
|
52
|
+
// data: { id: handleId, variablePara },
|
|
53
|
+
}
|
|
54
|
+
}).then(function (res) {
|
|
55
|
+
if (res.code == 200) {
|
|
56
|
+
setConfig(res.data);
|
|
57
|
+
}
|
|
58
|
+
});
|
|
59
|
+
};
|
|
60
|
+
useEffect(function () {
|
|
61
|
+
getConfig();
|
|
62
|
+
}, [formTemplateCode]);
|
|
63
|
+
var changeDate = function changeDate(vals) {
|
|
64
|
+
setDataSource(vals);
|
|
65
|
+
};
|
|
66
|
+
var hanldeOk = function hanldeOk() {
|
|
67
|
+
var _props$onChange;
|
|
68
|
+
(_props$onChange = props.onChange) === null || _props$onChange === void 0 || _props$onChange.call(props, dataSource);
|
|
69
|
+
};
|
|
70
|
+
return /*#__PURE__*/React.createElement(React.Fragment, null, disabled ? /*#__PURE__*/React.createElement("span", null, props.value && formatStr(props.value, fontSplit, groupSplit)) : /*#__PURE__*/React.createElement(ChooseModal, {
|
|
71
|
+
params: {
|
|
72
|
+
config: {
|
|
73
|
+
name: config === null || config === void 0 ? void 0 : config.formTemplateName
|
|
74
|
+
}
|
|
75
|
+
}
|
|
76
|
+
// width={'800'}
|
|
77
|
+
,
|
|
78
|
+
modalNode: function modalNode() {
|
|
79
|
+
return /*#__PURE__*/React.createElement("div", {
|
|
80
|
+
style: {
|
|
81
|
+
display: 'flex'
|
|
82
|
+
}
|
|
83
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
84
|
+
style: {
|
|
85
|
+
border: "1px solid #d9d9d9",
|
|
86
|
+
width: '100%',
|
|
87
|
+
minHeight: '30px',
|
|
88
|
+
marginRight: '4px',
|
|
89
|
+
padding: '6px 11px'
|
|
90
|
+
}
|
|
91
|
+
}, props.value && formatStr(props.value, fontSplit, groupSplit)), /*#__PURE__*/React.createElement(Button, {
|
|
92
|
+
icon: "icon-edit"
|
|
93
|
+
}));
|
|
94
|
+
},
|
|
95
|
+
showFooter: true,
|
|
96
|
+
callbackShow: function callbackShow(flag) {
|
|
97
|
+
setVisible(flag);
|
|
98
|
+
},
|
|
99
|
+
hanldeOk: hanldeOk
|
|
100
|
+
}, /*#__PURE__*/React.createElement(ETable2, {
|
|
101
|
+
menuCode: menuCode,
|
|
102
|
+
config: config,
|
|
103
|
+
value: dataSource,
|
|
104
|
+
onChange: changeDate
|
|
105
|
+
})));
|
|
106
|
+
};
|
|
107
|
+
export function formatStr(arr) {
|
|
108
|
+
var fontSplit = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : ',';
|
|
109
|
+
var groupSplit = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : ';';
|
|
110
|
+
var str = '';
|
|
111
|
+
arr === null || arr === void 0 || arr.forEach(function (item, index) {
|
|
112
|
+
var chiStr = '';
|
|
113
|
+
for (var k in arr[0]) {
|
|
114
|
+
if (!['id', 'chosen', 'selected'].includes(k)) {
|
|
115
|
+
chiStr = chiStr ? "".concat(chiStr).concat(fontSplit || ',').concat(item[k]) : "".concat(item[k]);
|
|
116
|
+
}
|
|
117
|
+
}
|
|
118
|
+
str = str ? "".concat(str).concat(groupSplit || ';').concat(chiStr) : "".concat(chiStr);
|
|
119
|
+
});
|
|
120
|
+
return str;
|
|
121
|
+
}
|
|
122
|
+
export default connect()(Index);
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import type { ExpressModalProps } from '@/components/v2/Modal';
|
|
3
|
+
interface ExpressProps extends ExpressModalProps {
|
|
4
|
+
style?: React.CSSProperties;
|
|
5
|
+
}
|
|
6
|
+
declare const Express: React.FC<ExpressProps>;
|
|
7
|
+
export default Express;
|
|
8
|
+
//# sourceMappingURL=Express.d.ts.map
|