ls-pro-common 1.1.1 → 1.1.3

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 (54) hide show
  1. package/dist/common.css +66 -3
  2. package/dist/common.js +1 -1
  3. package/dist/common.js.LICENSE.txt +14 -3
  4. package/dist/common.min.css +66 -3
  5. package/dist/common.min.js +1 -1
  6. package/dist/common.min.js.LICENSE.txt +14 -3
  7. package/es/components/AreaCascader.js +35 -48
  8. package/es/components/AreaCascaderPanel.js +55 -85
  9. package/es/components/DescritionCard.js +14 -19
  10. package/es/components/DtlLayout.js +25 -38
  11. package/es/components/IconSelector.js +27 -50
  12. package/es/components/ImageSelector.js +89 -139
  13. package/es/components/InputMultiLine.js +33 -45
  14. package/es/components/InputTable.js +118 -160
  15. package/es/components/Loading.js +3 -6
  16. package/es/components/Permission.d.ts +6 -0
  17. package/es/components/Permission.js +10 -0
  18. package/es/components/common.less +63 -0
  19. package/es/hooks/useDtl/index.d.ts +2 -2
  20. package/es/hooks/useDtl/index.js +685 -950
  21. package/es/hooks/usePermission/index.js +0 -9
  22. package/es/hooks/useSingle/index.d.ts +3 -3
  23. package/es/hooks/useSingle/index.js +431 -603
  24. package/es/http/index.js +116 -154
  25. package/es/index.d.ts +4 -2
  26. package/es/index.js +2 -2
  27. package/es/service/BaseService.js +121 -195
  28. package/es/utils/index.d.ts +9 -22
  29. package/es/utils/index.js +63 -181
  30. package/lib/components/404.js +1 -6
  31. package/lib/components/AreaCascader.js +37 -63
  32. package/lib/components/AreaCascaderPanel.js +57 -105
  33. package/lib/components/DescritionCard.js +16 -33
  34. package/lib/components/DtlLayout.js +27 -49
  35. package/lib/components/IconSelector.js +29 -64
  36. package/lib/components/ImageSelector.js +91 -162
  37. package/lib/components/InputMultiLine.js +35 -61
  38. package/lib/components/InputTable.js +120 -185
  39. package/lib/components/Loading.js +4 -16
  40. package/lib/components/Permission.d.ts +6 -0
  41. package/lib/components/Permission.js +18 -0
  42. package/lib/components/common.less +63 -0
  43. package/lib/hooks/useDtl/index.d.ts +2 -2
  44. package/lib/hooks/useDtl/index.js +686 -966
  45. package/lib/hooks/usePermission/index.js +0 -12
  46. package/lib/hooks/useSingle/index.d.ts +3 -3
  47. package/lib/hooks/useSingle/index.js +432 -618
  48. package/lib/http/index.js +114 -163
  49. package/lib/index.d.ts +4 -2
  50. package/lib/index.js +9 -21
  51. package/lib/service/BaseService.js +121 -201
  52. package/lib/utils/index.d.ts +9 -22
  53. package/lib/utils/index.js +85 -290
  54. package/package.json +2 -2
@@ -6,12 +6,12 @@ import _extends from "@babel/runtime/helpers/esm/extends";
6
6
  import "antd/es/button/style";
7
7
  import _Button from "antd/es/button";
8
8
  import _objectSpread from "@babel/runtime/helpers/esm/objectSpread2";
9
- import _regeneratorRuntime from "@babel/runtime/regenerator";
10
9
  import _asyncToGenerator from "@babel/runtime/helpers/esm/asyncToGenerator";
11
10
  import _objectWithoutProperties from "@babel/runtime/helpers/esm/objectWithoutProperties";
12
11
  import _slicedToArray from "@babel/runtime/helpers/esm/slicedToArray";
13
12
  var _excluded = ["columns", "url", "textName", "name", "tableConfig", "tableHeight", "tableWidth", "readonly", "multiple", "valueField", "labelWidth", "textField", "onSelectChange", "beforeLoad", "afterLoad", "isV2", "allowClear", "keepSelect", "fieldProps", "searchField", "fillMap", "loadOnShow", "triggerCheck", "getPopupContainer", "placement", "arrowPointAtCenter"],
14
- _excluded2 = ["current", "pageSize"];
13
+ _excluded2 = ["current", "pageSize"];
14
+ import _regeneratorRuntime from "@babel/runtime/regenerator";
15
15
  import React, { useRef, useState, useEffect, useContext, useMemo, useImperativeHandle } from 'react';
16
16
  import ProTable from 'ls-pro-table';
17
17
  import { ProFormText, ProFormContext } from 'ls-pro-form';
@@ -21,202 +21,173 @@ import { showWarn } from '../utils';
21
21
  var InputTable = /*#__PURE__*/React.forwardRef(function (prop, ref) {
22
22
  //@ts-ignore
23
23
  var _useContext = useContext(ProFormContext),
24
- formRef = _useContext.formRef;
25
-
24
+ formRef = _useContext.formRef;
26
25
  var tableRef = useRef();
27
-
28
26
  var _useState = useState(false),
29
- _useState2 = _slicedToArray(_useState, 2),
30
- visible = _useState2[0],
31
- setVisible = _useState2[1];
32
-
27
+ _useState2 = _slicedToArray(_useState, 2),
28
+ visible = _useState2[0],
29
+ setVisible = _useState2[1];
33
30
  var _useState3 = useState([]),
34
- _useState4 = _slicedToArray(_useState3, 2),
35
- selectedRows = _useState4[0],
36
- setSelectedRows = _useState4[1];
37
-
31
+ _useState4 = _slicedToArray(_useState3, 2),
32
+ selectedRows = _useState4[0],
33
+ setSelectedRows = _useState4[1];
38
34
  var _useState5 = useState(''),
39
- _useState6 = _slicedToArray(_useState5, 2),
40
- text = _useState6[0],
41
- setText = _useState6[1];
42
-
35
+ _useState6 = _slicedToArray(_useState5, 2),
36
+ text = _useState6[0],
37
+ setText = _useState6[1];
43
38
  var inputRef = useRef();
44
39
  useImperativeHandle(ref, function () {
45
40
  return inputRef.current;
46
41
  });
47
-
48
42
  var columns = prop.columns,
49
- url = prop.url,
50
- textName = prop.textName,
51
- name = prop.name,
52
- tableConfig = prop.tableConfig,
53
- _prop$tableHeight = prop.tableHeight,
54
- tableHeight = _prop$tableHeight === void 0 ? 400 : _prop$tableHeight,
55
- _prop$tableWidth = prop.tableWidth,
56
- tableWidth = _prop$tableWidth === void 0 ? 650 : _prop$tableWidth,
57
- _prop$readonly = prop.readonly,
58
- readonly = _prop$readonly === void 0 ? true : _prop$readonly,
59
- multiple = prop.multiple,
60
- valueField = prop.valueField,
61
- _prop$labelWidth = prop.labelWidth,
62
- labelWidth = _prop$labelWidth === void 0 ? 70 : _prop$labelWidth,
63
- textField = prop.textField,
64
- onSelectChange = prop.onSelectChange,
65
- beforeLoad = prop.beforeLoad,
66
- afterLoad = prop.afterLoad,
67
- _prop$isV = prop.isV2,
68
- isV2 = _prop$isV === void 0 ? false : _prop$isV,
69
- _prop$allowClear = prop.allowClear,
70
- allowClear = _prop$allowClear === void 0 ? true : _prop$allowClear,
71
- _prop$keepSelect = prop.keepSelect,
72
- keepSelect = _prop$keepSelect === void 0 ? false : _prop$keepSelect,
73
- fieldProps = prop.fieldProps,
74
- searchField = prop.searchField,
75
- fillMap = prop.fillMap,
76
- _prop$loadOnShow = prop.loadOnShow,
77
- loadOnShow = _prop$loadOnShow === void 0 ? false : _prop$loadOnShow,
78
- _prop$triggerCheck = prop.triggerCheck,
79
- triggerCheck = _prop$triggerCheck === void 0 ? 'entry' : _prop$triggerCheck,
80
- _prop$getPopupContain = prop.getPopupContainer,
81
- getPopupContainer = _prop$getPopupContain === void 0 ? function (triggerNode) {
82
- return triggerNode.parentNode.parentNode.parentNode.parentNode;
83
- } : _prop$getPopupContain,
84
- _prop$placement = prop.placement,
85
- placement = _prop$placement === void 0 ? 'bottom' : _prop$placement,
86
- _prop$arrowPointAtCen = prop.arrowPointAtCenter,
87
- arrowPointAtCenter = _prop$arrowPointAtCen === void 0 ? true : _prop$arrowPointAtCen,
88
- rest = _objectWithoutProperties(prop, _excluded); //显示输入框绑定的name,如果不设置textName,设置为$name__text
89
-
90
-
43
+ url = prop.url,
44
+ textName = prop.textName,
45
+ name = prop.name,
46
+ tableConfig = prop.tableConfig,
47
+ _prop$tableHeight = prop.tableHeight,
48
+ tableHeight = _prop$tableHeight === void 0 ? 400 : _prop$tableHeight,
49
+ _prop$tableWidth = prop.tableWidth,
50
+ tableWidth = _prop$tableWidth === void 0 ? 650 : _prop$tableWidth,
51
+ _prop$readonly = prop.readonly,
52
+ readonly = _prop$readonly === void 0 ? true : _prop$readonly,
53
+ multiple = prop.multiple,
54
+ valueField = prop.valueField,
55
+ _prop$labelWidth = prop.labelWidth,
56
+ labelWidth = _prop$labelWidth === void 0 ? 70 : _prop$labelWidth,
57
+ textField = prop.textField,
58
+ onSelectChange = prop.onSelectChange,
59
+ beforeLoad = prop.beforeLoad,
60
+ afterLoad = prop.afterLoad,
61
+ _prop$isV = prop.isV2,
62
+ isV2 = _prop$isV === void 0 ? false : _prop$isV,
63
+ _prop$allowClear = prop.allowClear,
64
+ allowClear = _prop$allowClear === void 0 ? true : _prop$allowClear,
65
+ _prop$keepSelect = prop.keepSelect,
66
+ keepSelect = _prop$keepSelect === void 0 ? false : _prop$keepSelect,
67
+ fieldProps = prop.fieldProps,
68
+ searchField = prop.searchField,
69
+ fillMap = prop.fillMap,
70
+ _prop$loadOnShow = prop.loadOnShow,
71
+ loadOnShow = _prop$loadOnShow === void 0 ? false : _prop$loadOnShow,
72
+ _prop$triggerCheck = prop.triggerCheck,
73
+ triggerCheck = _prop$triggerCheck === void 0 ? 'entry' : _prop$triggerCheck,
74
+ _prop$getPopupContain = prop.getPopupContainer,
75
+ getPopupContainer = _prop$getPopupContain === void 0 ? function (triggerNode) {
76
+ return triggerNode.parentNode.parentNode.parentNode.parentNode;
77
+ } : _prop$getPopupContain,
78
+ _prop$placement = prop.placement,
79
+ placement = _prop$placement === void 0 ? 'bottom' : _prop$placement,
80
+ _prop$arrowPointAtCen = prop.arrowPointAtCenter,
81
+ arrowPointAtCenter = _prop$arrowPointAtCen === void 0 ? true : _prop$arrowPointAtCen,
82
+ rest = _objectWithoutProperties(prop, _excluded);
83
+ //显示输入框绑定的name,如果不设置textName,设置为$name__text
91
84
  var textNameProp = useMemo(function () {
92
85
  return textName || name + '__text';
93
- }, [textName, name]); // 输入框回车时,调用查询参数字段
94
-
86
+ }, [textName, name]);
87
+ // 输入框回车时,调用查询参数字段
95
88
  var searchKey = useMemo(function () {
96
89
  if (searchField) return searchField;
97
- var col; //先取显示字段
98
-
90
+ var col;
91
+ //先取显示字段
99
92
  if (textField) {
100
93
  col = columns.find(function (o) {
101
94
  return o.dataIndex === textField || o.key === textField;
102
95
  });
103
- } //取不到时取值字段
104
-
105
-
96
+ }
97
+ //取不到时取值字段
106
98
  if (!col) {
107
99
  col = columns.find(function (o) {
108
100
  return o.dataIndex === valueField || o.key === valueField;
109
101
  });
110
102
  }
111
-
112
103
  if (col) return col.searchField || col.dataIndex;
113
104
  return textField || valueField;
114
105
  }, [columns, searchField, valueField, textField]);
115
-
116
106
  var loadData = /*#__PURE__*/function () {
117
107
  var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee(param) {
118
108
  var current, pageSize, rest, data, _tableRef$current, _tableRef$current$cle, result, rows;
119
-
120
109
  return _regeneratorRuntime.wrap(function _callee$(_context) {
121
- while (1) {
122
- switch (_context.prev = _context.next) {
123
- case 0:
124
- current = param.current, pageSize = param.pageSize, rest = _objectWithoutProperties(param, _excluded2);
125
- data = {};
126
-
127
- if (isV2) {
128
- data['page.pn'] = current;
129
- data['page.size'] = pageSize;
130
- } else {
131
- data.page = current;
132
- data.pageSize = pageSize;
133
- }
134
-
135
- ;
136
-
137
- if (Object.keys(rest).length && !isV2) {
138
- data.where = rest;
139
- }
140
-
141
- if (!keepSelect) {
142
- setSelectedRows([]);
143
- (_tableRef$current = tableRef.current) === null || _tableRef$current === void 0 ? void 0 : (_tableRef$current$cle = _tableRef$current.clearSelected) === null || _tableRef$current$cle === void 0 ? void 0 : _tableRef$current$cle.call(_tableRef$current);
144
- }
145
-
146
- if (beforeLoad) {
147
- beforeLoad(data);
148
- }
149
-
150
- ;
151
- _context.next = 10;
152
- return httpGet(url, data);
153
-
154
- case 10:
155
- result = _context.sent;
156
- rows = result.rows || [];
157
-
158
- if (afterLoad) {
159
- afterLoad(rows);
160
- }
161
-
162
- return _context.abrupt("return", {
163
- data: rows,
164
- total: Number(result.total || 0),
165
- success: true
166
- });
167
-
168
- case 14:
169
- case "end":
170
- return _context.stop();
171
- }
110
+ while (1) switch (_context.prev = _context.next) {
111
+ case 0:
112
+ current = param.current, pageSize = param.pageSize, rest = _objectWithoutProperties(param, _excluded2);
113
+ data = {};
114
+ if (isV2) {
115
+ data['page.pn'] = current;
116
+ data['page.size'] = pageSize;
117
+ } else {
118
+ data.page = current;
119
+ data.pageSize = pageSize;
120
+ }
121
+ ;
122
+ if (Object.keys(rest).length && !isV2) {
123
+ data.where = rest;
124
+ }
125
+ if (!keepSelect) {
126
+ setSelectedRows([]);
127
+ (_tableRef$current = tableRef.current) === null || _tableRef$current === void 0 ? void 0 : (_tableRef$current$cle = _tableRef$current.clearSelected) === null || _tableRef$current$cle === void 0 ? void 0 : _tableRef$current$cle.call(_tableRef$current);
128
+ }
129
+ if (beforeLoad) {
130
+ beforeLoad(data);
131
+ }
132
+ ;
133
+ _context.next = 10;
134
+ return httpGet(url, data);
135
+ case 10:
136
+ result = _context.sent;
137
+ rows = result.rows || [];
138
+ if (afterLoad) {
139
+ afterLoad(rows);
140
+ }
141
+ return _context.abrupt("return", {
142
+ data: rows,
143
+ total: Number(result.total || 0),
144
+ success: true
145
+ });
146
+ case 14:
147
+ case "end":
148
+ return _context.stop();
172
149
  }
173
150
  }, _callee);
174
151
  }));
175
-
176
152
  return function loadData(_x) {
177
153
  return _ref.apply(this, arguments);
178
154
  };
179
- }(); // 初始化数据
180
-
181
-
155
+ }();
156
+ // 初始化数据
182
157
  useEffect(function () {
183
158
  setTimeout(function () {
184
159
  var _formRef$current, _formRef$current2;
185
-
186
160
  var txt = formRef === null || formRef === void 0 ? void 0 : (_formRef$current = formRef.current) === null || _formRef$current === void 0 ? void 0 : _formRef$current.getFieldValue(textNameProp);
187
161
  var val = formRef === null || formRef === void 0 ? void 0 : (_formRef$current2 = formRef.current) === null || _formRef$current2 === void 0 ? void 0 : _formRef$current2.getFieldValue(name);
188
-
189
162
  if (txt) {
190
163
  setText(txt);
191
164
  } else if (val) {
192
165
  setText(val);
193
166
  }
194
167
  }, 0);
195
- }, []); // 处理返回数据
196
-
168
+ }, []);
169
+ // 处理返回数据
197
170
  var handleValue = function handleValue(row) {
198
171
  var _formRef$current3, _formRef$current4;
199
-
200
172
  var formValue = formRef === null || formRef === void 0 ? void 0 : (_formRef$current3 = formRef.current) === null || _formRef$current3 === void 0 ? void 0 : _formRef$current3.getFieldsValue();
201
- var txt; //支持多选
202
-
173
+ var txt;
174
+ //支持多选
203
175
  if (Array.isArray(row)) {
204
176
  //返回值
205
177
  formValue[name] = row.map(function (o) {
206
178
  return o[valueField];
207
- }).join(','); //显示值
208
-
179
+ }).join(',');
180
+ //显示值
209
181
  txt = row.map(function (o) {
210
182
  return o[textField || valueField];
211
- }).join(','); //处理填充其它字段
212
-
183
+ }).join(',');
184
+ //处理填充其它字段
213
185
  if (fillMap) {
214
186
  var _loop = function _loop(key) {
215
187
  formValue[key] = row.map(function (o) {
216
188
  return o[fillMap[key]];
217
189
  }).join(',');
218
190
  };
219
-
220
191
  for (var key in fillMap) {
221
192
  _loop(key);
222
193
  }
@@ -224,26 +195,22 @@ var InputTable = /*#__PURE__*/React.forwardRef(function (prop, ref) {
224
195
  } else {
225
196
  formValue[name] = row[valueField] || '';
226
197
  txt = row[textField || valueField] || '';
227
-
228
198
  if (fillMap) {
229
199
  for (var _key in fillMap) {
230
200
  formValue[_key] = row[fillMap[_key]] || '';
231
201
  }
232
202
  }
233
203
  }
234
-
235
204
  formValue[textNameProp] = txt;
236
205
  setText(txt);
237
206
  setVisible(false);
238
207
  (_formRef$current4 = formRef.current) === null || _formRef$current4 === void 0 ? void 0 : _formRef$current4.setFieldsValue(_objectSpread({}, formValue));
239
208
  onSelectChange === null || onSelectChange === void 0 ? void 0 : onSelectChange(row, formRef);
240
- }; // 可输入时,回车或失去焦点调接口查询数据
241
-
242
-
209
+ };
210
+ // 可输入时,回车或失去焦点调接口查询数据
243
211
  var onQuery = function onQuery(e) {
244
212
  if (rest.disabled || (fieldProps === null || fieldProps === void 0 ? void 0 : fieldProps.disabled) || readonly) return;
245
213
  var val = e.target.value;
246
-
247
214
  if (val) {
248
215
  var param = {
249
216
  current: 1,
@@ -252,7 +219,6 @@ var InputTable = /*#__PURE__*/React.forwardRef(function (prop, ref) {
252
219
  param[searchKey] = val;
253
220
  loadData(param).then(function (result) {
254
221
  var rows = result.data || [];
255
-
256
222
  if (!rows.length) {
257
223
  handleValue({});
258
224
  showWarn("".concat(val, "\u67E5\u627E\u4E0D\u5230\u5BF9\u5E94\u7684\u8BB0\u5F55\uFF01"));
@@ -265,43 +231,37 @@ var InputTable = /*#__PURE__*/React.forwardRef(function (prop, ref) {
265
231
  e.stopPropagation();
266
232
  e.preventDefault();
267
233
  }
268
- }; //直接输入不回车,value 和 text 为同一个值
269
-
270
-
234
+ };
235
+ //直接输入不回车,value 和 text 为同一个值
271
236
  var onInput = function onInput(e) {
272
237
  var _formRef$current5;
273
-
274
238
  var formValue = formRef === null || formRef === void 0 ? void 0 : (_formRef$current5 = formRef.current) === null || _formRef$current5 === void 0 ? void 0 : _formRef$current5.getFieldsValue();
275
239
  var val = e.target.value;
276
240
  formValue[name] = val;
277
241
  formValue[textNameProp] = val;
278
242
  setText(val);
279
243
  formRef.current.setFieldsValue(_objectSpread({}, formValue));
280
- }; // 当表单重置或点clear时,处理值
281
-
282
-
244
+ };
245
+ // 当表单重置或点clear时,处理值
283
246
  var clearValue = function clearValue(e) {
284
247
  if (!e.target.value) {
285
248
  var _formRef$current6;
286
-
287
249
  setText('');
288
250
  var formValue = formRef === null || formRef === void 0 ? void 0 : (_formRef$current6 = formRef.current) === null || _formRef$current6 === void 0 ? void 0 : _formRef$current6.getFieldsValue();
289
251
  formValue[name] = '';
290
- formValue[textNameProp] = ''; // 不处理,其它表单自己清空
252
+ formValue[textNameProp] = '';
253
+ // 不处理,其它表单自己清空
291
254
  // if (fillMap) {
292
255
  // for (let key in fillMap) {
293
256
  // formValue[key] = '';
294
257
  // }
295
258
  // }
296
-
297
259
  formRef.current.setFieldsValue(_objectSpread({}, formValue));
298
260
  }
299
261
  };
300
-
301
262
  useEffect(function () {
302
263
  if (!text) {
303
264
  var _tableRef$current2, _tableRef$current2$cl;
304
-
305
265
  setSelectedRows([]);
306
266
  (_tableRef$current2 = tableRef.current) === null || _tableRef$current2 === void 0 ? void 0 : (_tableRef$current2$cl = _tableRef$current2.clearSelected) === null || _tableRef$current2$cl === void 0 ? void 0 : _tableRef$current2$cl.call(_tableRef$current2);
307
267
  }
@@ -348,15 +308,13 @@ var InputTable = /*#__PURE__*/React.forwardRef(function (prop, ref) {
348
308
  }, "\u786E\u8BA4")];
349
309
  },
350
310
  headerTitle: "\u53CC\u51FB\u9009\u4E2D\u5F53\u524D\u884C\u6570\u636E"
351
- }, tableConfig)); // 处理有值时,可清空
352
-
311
+ }, tableConfig));
312
+ // 处理有值时,可清空
353
313
  useEffect(function () {
354
314
  if (rest.disabled || (fieldProps === null || fieldProps === void 0 ? void 0 : fieldProps.disabled)) return;
355
-
356
315
  try {
357
316
  var el = inputRef.current.input.parentNode;
358
317
  if (!el) return;
359
-
360
318
  if (text) {
361
319
  el.classList.add('ant-input-has-value');
362
320
  } else {
@@ -7,16 +7,13 @@ import React from 'react';
7
7
  import './common.less';
8
8
  export default (function (props) {
9
9
  var _props$Text = props.Text,
10
- Text = _props$Text === void 0 ? '加载中...' : _props$Text,
11
- className = props.className,
12
- rest = _objectWithoutProperties(props, _excluded);
13
-
10
+ Text = _props$Text === void 0 ? '加载中...' : _props$Text,
11
+ className = props.className,
12
+ rest = _objectWithoutProperties(props, _excluded);
14
13
  var cls = "loading";
15
-
16
14
  if (className) {
17
15
  cls += " " + className;
18
16
  }
19
-
20
17
  return /*#__PURE__*/React.createElement("div", _extends({
21
18
  className: cls
22
19
  }, rest), " ", /*#__PURE__*/React.createElement(_Spin, null), Text);
@@ -0,0 +1,6 @@
1
+ import React from 'react';
2
+ export declare type PermissionProps = {
3
+ rightValue: number;
4
+ };
5
+ declare const Permission: React.FC<PermissionProps>;
6
+ export default Permission;
@@ -0,0 +1,10 @@
1
+ import React from 'react';
2
+ import usePermission from "../hooks/usePermission";
3
+ var Permission = function Permission(_ref) {
4
+ var children = _ref.children,
5
+ rightValue = _ref.rightValue;
6
+ var _usePermission = usePermission(),
7
+ checkRight = _usePermission.checkRight;
8
+ return checkRight(rightValue) ? /*#__PURE__*/React.createElement(React.Fragment, null, children) : null;
9
+ };
10
+ export default Permission;
@@ -82,6 +82,69 @@ body {
82
82
  // --ant-info-color-deprecated-border : #ccebff;
83
83
  }
84
84
 
85
+
86
+ body.theme-yellow {
87
+ --ant-primary-color: #fa8500;
88
+ --ant-primary-color-hover: #ffa229;
89
+ --ant-primary-color-active: #d46a00;
90
+ --ant-primary-color-outline: rgba(250, 133, 0, 0.2);
91
+ --ant-primary-bg: #fff;
92
+ --ant-primary-side: #fff7e6;
93
+ --ant-primary-0: #ffd9ad;
94
+ --ant-primary-1: #fff7e6;
95
+ --ant-primary-2: #ffe0a3;
96
+ --ant-primary-3: #ffce7a;
97
+ --ant-primary-4: #ffba52;
98
+ --ant-primary-5: #ffa229;
99
+ --ant-primary-6: #fa8500;
100
+ --ant-primary-7: #d46a00;
101
+ --ant-primary-color-deprecated-pure: #ffd9ad;
102
+ --ant-primary-color-deprecated-l-35: #ffd9ad;
103
+ --ant-primary-color-deprecated-l-20: #ffb561;
104
+ --ant-primary-color-deprecated-t-20: #fb9d33;
105
+ --ant-primary-color-deprecated-t-50: #fdc280;
106
+ --ant-primary-color-deprecated-f-12: rgba(250, 133, 0, 0.12);
107
+ --ant-primary-color-active-deprecated-f-30: rgba(255, 247, 230, 0.3);
108
+ --ant-primary-color-active-deprecated-d-02: #fff4dc;
109
+ --ant-success-color: #52c41a;
110
+ --ant-success-color-hover: #73d13d;
111
+ --ant-success-color-active: #389e0d;
112
+ --ant-success-color-outline: rgba(82, 196, 26, 0.2);
113
+ --ant-success-color-deprecated-bg: #f6ffed;
114
+ --ant-success-color-deprecated-border: #b7eb8f;
115
+ --ant-error-color: #ff4d4f;
116
+ --ant-error-color-hover: #ff7875;
117
+ --ant-error-color-active: #d9363e;
118
+ --ant-error-color-outline: rgba(255, 77, 79, 0.2);
119
+ --ant-error-color-deprecated-bg: #fff2f0;
120
+ --ant-error-color-deprecated-border: #ffccc7;
121
+ --ant-warning-color: #faad14;
122
+ --ant-warning-color-hover: #ffc53d;
123
+ --ant-warning-color-active: #d48806;
124
+ --ant-warning-color-outline: rgba(250, 173, 20, 0.2);
125
+ --ant-warning-color-deprecated-bg: #fffbe6;
126
+ --ant-warning-color-deprecated-border: #ffe58f;
127
+ --ant-info-color: #fa8500;
128
+ --ant-info-color-deprecated-bg: #fff7e6;
129
+ --ant-info-color-deprecated-border: #ffce7a;
130
+ --antd-wave-shadow-color: #fa8500;
131
+
132
+ .ant-table-cell,
133
+ .ant-pro-table-alert-info-content {
134
+ a {
135
+ color: var(--ant-primary-color);
136
+ }
137
+
138
+ a:hover {
139
+ color: var(--ant-primary-color-hover);
140
+ }
141
+
142
+ a:active {
143
+ color: var(--ant-primary-color-active);
144
+ }
145
+ }
146
+ }
147
+
85
148
  .dtl-layout {
86
149
  position : absolute;
87
150
  top : 0;
@@ -19,8 +19,8 @@ export declare type DtlParamType = SingleParamType & {
19
19
  billType?: string;
20
20
  /**@name 动态编码规则字段,主从表一起保存传参 */
21
21
  codeRuleDynamicField?: string;
22
- /**@是否查询历史数据 */
23
- ifHistoryData?: 0 | 1;
22
+ /** 是否查询历史数据,通过主表查询面板用户受控组件传入 */
23
+ ifHistory?: 0 | 1;
24
24
  };
25
25
  declare function useDtl(dtlParam: DtlParamType): {
26
26
  formRef: import("react").MutableRefObject<ProFormInstance<any> | undefined>;