@zgfe/business-lib 1.2.58-ljy.0 → 1.2.70-hxd.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.
Files changed (95) hide show
  1. package/README.md +1 -1
  2. package/es/AUMFormulaTarget/components/formula/index.less +5 -1
  3. package/es/AUMFormulaTarget/components/formulaItem/index.js +52 -13
  4. package/es/AUMFormulaTarget/demo/index.js +1 -1
  5. package/es/assets/iconfont/demo_index.html +233 -3
  6. package/es/assets/iconfont/iconfont.css +43 -3
  7. package/es/assets/iconfont/iconfont.js +8 -8
  8. package/es/assets/iconfont/iconfont.json +70 -0
  9. package/es/assets/iconfont/iconfont.ttf +0 -0
  10. package/es/assets/iconfont/iconfont.woff +0 -0
  11. package/es/assets/iconfont/iconfont.woff2 +0 -0
  12. package/es/assets/images/attention.png +0 -0
  13. package/es/assets/styles/resetAntd.less +20 -7
  14. package/es/attrCondition/group.js +5 -2
  15. package/es/attrCondition/index.js +6 -2
  16. package/es/attrConditions/components/operateList.js +4 -4
  17. package/es/attrConditions/components/stringList.d.ts +10 -0
  18. package/es/attrConditions/components/stringList.js +57 -27
  19. package/es/attrConditions/components/valuesList.d.ts +10 -0
  20. package/es/attrConditions/components/valuesList.js +7 -3
  21. package/es/attrConditions/types.d.ts +17 -0
  22. package/es/attributeSelector/index.js +9 -3
  23. package/es/attributeSelector/listPanel.js +8 -4
  24. package/es/attributeSelector/types.d.ts +3 -0
  25. package/es/attributeSelector/util.js +1 -0
  26. package/es/chart/demo/data/data7.d.ts +54 -0
  27. package/es/chart/demo/data/data7.js +1527 -0
  28. package/es/chart/demo/index.js +2 -3
  29. package/es/chart/demo/stack.d.ts +3 -0
  30. package/es/chart/demo/stack.js +31 -0
  31. package/es/chart/index.js +16 -6
  32. package/es/chart/types.d.ts +4 -1
  33. package/es/chart/util/chartOptionConfig.d.ts +4 -3
  34. package/es/chart/util/chartOptionConfig.js +84 -4
  35. package/es/chart/util/formatData.d.ts +1 -0
  36. package/es/chart/util/formatData.js +13 -0
  37. package/es/chart/util/formatOption.js +1 -1
  38. package/es/constants/apis.d.ts +3 -0
  39. package/es/constants/apis.js +4 -1
  40. package/es/cycleTime/index.js +1 -1
  41. package/es/datePicker/index.js +6 -6
  42. package/es/datePickerV2/index.js +6 -3
  43. package/es/datePickerV2/popoverContent.d.ts +1 -0
  44. package/es/datePickerV2/popoverContent.js +3 -1
  45. package/es/datePickerV2/shortcut.d.ts +2 -0
  46. package/es/datePickerV2/shortcut.js +4 -3
  47. package/es/datePickerV2/types.d.ts +2 -0
  48. package/es/datePickerV2/utils.d.ts +1 -1
  49. package/es/datePickerV2/utils.js +5 -5
  50. package/es/empty/demo/index.d.ts +4 -0
  51. package/es/empty/demo/index.js +16 -0
  52. package/es/empty/index.d.ts +4 -0
  53. package/es/empty/index.js +19 -0
  54. package/es/empty/types.d.ts +7 -0
  55. package/es/empty/types.js +1 -0
  56. package/es/hooks/useBizStore.d.ts +4 -2
  57. package/es/hooks/useBizStore.js +18 -14
  58. package/es/index.d.ts +6 -1
  59. package/es/index.js +6 -1
  60. package/es/platformSelector/index.js +42 -9
  61. package/es/platformSelector/styles/index.less +6 -2
  62. package/es/platformSelector/util.d.ts +1 -1
  63. package/es/platformSelector/util.js +8 -1
  64. package/es/productCondition/conditions/order/runPeriodCondition.js +1 -1
  65. package/es/productCondition/conditions/periodCondition.js +1 -1
  66. package/es/productCondition/conditions/runTimesCondition.js +1 -1
  67. package/es/select/index.js +9 -1
  68. package/es/select/types.d.ts +3 -2
  69. package/es/subjectWrapper/demo/index.d.ts +3 -0
  70. package/es/subjectWrapper/demo/index.js +28 -0
  71. package/es/subjectWrapper/index.d.ts +5 -0
  72. package/es/subjectWrapper/index.js +98 -0
  73. package/es/subjectWrapper/index.less +12 -0
  74. package/es/subjectWrapper/types.d.ts +14 -0
  75. package/es/subjectWrapper/types.js +4 -0
  76. package/es/targetConditionGroup/index.js +5 -4
  77. package/es/userCondition/conditionTypeList.js +1 -10
  78. package/es/userCondition/conditions/businessCondition.js +3 -10
  79. package/es/userCondition/conditions/cdpCshCondition.js +0 -1
  80. package/es/userCondition/conditions/eventCondition.js +36 -4
  81. package/es/userCondition/conditions/order/runPeriodCondition.js +1 -1
  82. package/es/userCondition/conditions/periodCondition.js +1 -1
  83. package/es/userCondition/conditions/runTimesCondition.js +1 -1
  84. package/es/userCondition/conditions/styles/eventCondition.less +6 -0
  85. package/es/userCondition/conditions/textDesc.js +1 -24
  86. package/es/userCondition/orConditions.js +0 -7
  87. package/es/userGroup/index.js +2 -2
  88. package/es/userGroupHeader/demo/index.js +1 -1
  89. package/es/userTagsSelector/cascaderOverlay.js +13 -6
  90. package/es/userTagsSelector/demo/index.js +1 -0
  91. package/es/userTagsSelector/index.js +6 -3
  92. package/es/userTagsSelector/types.d.ts +2 -0
  93. package/es/utils/util.d.ts +3 -0
  94. package/es/utils/util.js +10 -0
  95. package/package.json +4 -4
@@ -506,7 +506,6 @@ var CdpCondition = function CdpCondition(props) {
506
506
  }
507
507
  }, []);
508
508
  var onChangeCondition = function onChangeCondition(condition, index) {
509
- console.log('onChangeCondition', condition, index);
510
509
  var resData = _.cloneDeep(cdpConditions);
511
510
  resData[index] = _objectSpread({}, condition);
512
511
  onChange(dataId, resData);
@@ -1,10 +1,16 @@
1
1
  function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
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(arr, i) { var _i = null == arr ? null : "undefined" != typeof Symbol && arr[Symbol.iterator] || arr["@@iterator"]; if (null != _i) { var _s, _e, _x, _r, _arr = [], _n = !0, _d = !1; try { if (_x = (_i = _i.call(arr)).next, 0 === i) { if (Object(_i) !== _i) return; _n = !1; } else for (; !(_n = (_s = _x.call(_i)).done) && (_arr.push(_s.value), _arr.length !== i); _n = !0); } catch (err) { _d = !0, _e = err; } finally { try { if (!_n && null != _i.return && (_r = _i.return(), Object(_r) !== _r)) return; } finally { if (_d) throw _e; } } return _arr; } }
7
+ function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
2
8
  function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
3
9
  function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
4
10
  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; }
5
11
  function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
6
12
  function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
7
- import React, { useContext } from 'react';
13
+ import React, { useContext, useEffect, useState } from 'react';
8
14
  import BizEventSelector from '../../eventSelector';
9
15
  import RunTimesCondition from './runTimesCondition';
10
16
  import PeriodCondition from './periodCondition';
@@ -17,12 +23,15 @@ import TimeDimension from './timeDimension';
17
23
  import { Tooltip } from 'antd';
18
24
  import IconFont from '../../icon/iconFont';
19
25
  import BizGlobalDataContext from '../../context';
26
+ import request from '../../utils/ajax';
27
+ import Apis from '../../constants/apis';
20
28
  var EventCondition = function EventCondition(props) {
21
29
  var _condition$timeDimens2, _condition$timeDimens3;
22
30
  var _useContext = useContext(BizUserConditionContext),
23
31
  isRealTime = _useContext.isRealTime;
24
32
  var _useContext2 = useContext(BizGlobalDataContext),
25
- currentUser = _useContext2.currentUser;
33
+ currentUser = _useContext2.currentUser,
34
+ currentApp = _useContext2.currentApp;
26
35
  var condition = props.condition,
27
36
  dataId = props.dataId;
28
37
  function onChange(data) {
@@ -89,6 +98,27 @@ var EventCondition = function EventCondition(props) {
89
98
  condition.timeDimensions.splice(index, 1);
90
99
  onChange(_objectSpread({}, condition));
91
100
  }
101
+ var _useState = useState(),
102
+ _useState2 = _slicedToArray(_useState, 2),
103
+ eventRemovedList = _useState2[0],
104
+ setEventRemovedList = _useState2[1];
105
+ function getEventRemoved() {
106
+ request(Apis.queryEventRemoved, {
107
+ method: 'post',
108
+ data: {
109
+ appId: currentApp === null || currentApp === void 0 ? void 0 : currentApp.appId
110
+ }
111
+ }).then(function (res) {
112
+ if ((res === null || res === void 0 ? void 0 : res.code) === '100000') {
113
+ setEventRemovedList(res === null || res === void 0 ? void 0 : res.data);
114
+ }
115
+ }).catch(function (err) {
116
+ console.error(err);
117
+ });
118
+ }
119
+ useEffect(function () {
120
+ getEventRemoved();
121
+ }, []);
92
122
  return /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("div", {
93
123
  className: "".concat(classPrefix, "-event-condition")
94
124
  }, /*#__PURE__*/React.createElement("div", {
@@ -111,7 +141,9 @@ var EventCondition = function EventCondition(props) {
111
141
  destroyPopupOnHide: true,
112
142
  defaultSelectAble: false,
113
143
  popupContainer: false
114
- })), /*#__PURE__*/React.createElement(Tooltip, {
144
+ }), condition && (eventRemovedList === null || eventRemovedList === void 0 ? void 0 : eventRemovedList.includes(condition.eventId)) && /*#__PURE__*/React.createElement("div", {
145
+ className: "del-log"
146
+ }, "\u4E8B\u4EF6\u5DF2\u88AB\u5220\u9664\uFF0C\u8BF7\u91CD\u65B0\u9009\u62E9")), /*#__PURE__*/React.createElement(Tooltip, {
115
147
  title: "\u6DFB\u52A0\u7B5B\u9009"
116
148
  }, /*#__PURE__*/React.createElement("div", {
117
149
  className: "".concat(classPrefix, "-event-condition-expand-attr"),
@@ -170,7 +202,7 @@ var EventCondition = function EventCondition(props) {
170
202
  }, /*#__PURE__*/React.createElement(IconFont, {
171
203
  type: "qingchu"
172
204
  }))));
173
- }), ((_condition$timeDimens3 = condition.timeDimensions) === null || _condition$timeDimens3 === void 0 ? void 0 : _condition$timeDimens3.length) < 3 && ((currentUser === null || currentUser === void 0 ? void 0 : currentUser.serviceType) === 0 || (currentUser === null || currentUser === void 0 ? void 0 : currentUser.serviceType) === 2) ? /*#__PURE__*/React.createElement("div", {
205
+ }), condition && !(eventRemovedList === null || eventRemovedList === void 0 ? void 0 : eventRemovedList.includes(condition.eventId)) && ((_condition$timeDimens3 = condition.timeDimensions) === null || _condition$timeDimens3 === void 0 ? void 0 : _condition$timeDimens3.length) < 3 && ((currentUser === null || currentUser === void 0 ? void 0 : currentUser.serviceType) === 0 || (currentUser === null || currentUser === void 0 ? void 0 : currentUser.serviceType) === 2) ? /*#__PURE__*/React.createElement("div", {
174
206
  style: {
175
207
  margin: '2px 0 0 38px',
176
208
  color: '#4075fd',
@@ -38,7 +38,7 @@ var RunPeriodCondition = function RunPeriodCondition(props) {
38
38
  }
39
39
  function onOperatorChange(option) {
40
40
  var newData = {
41
- operator: option.value
41
+ operator: option === null || option === void 0 ? void 0 : option.value
42
42
  };
43
43
  if (newData.operator === 'absolute') {
44
44
  var endDate = moment().format('YYYY-MM-DD');
@@ -47,7 +47,7 @@ var PeriodCondition = function PeriodCondition(props) {
47
47
  }
48
48
  function onOperatorChange(option) {
49
49
  var newData = {
50
- operator: option.value
50
+ operator: option === null || option === void 0 ? void 0 : option.value
51
51
  };
52
52
  if (newData.operator === 'absolute') {
53
53
  var endDate = moment().format('YYYY-MM-DD');
@@ -34,7 +34,7 @@ var RunTimesCondition = function RunTimesCondition(props) {
34
34
  onChange = props.onChange;
35
35
  function onOperatorChange(data) {
36
36
  onChange(_objectSpread(_objectSpread({}, runTimes), {}, {
37
- operator: data.value
37
+ operator: data === null || data === void 0 ? void 0 : data.value
38
38
  }));
39
39
  }
40
40
  function onValueChange(e) {
@@ -48,4 +48,10 @@
48
48
  &-runtimes {
49
49
  margin-right: @margin-xs;
50
50
  }
51
+ .del-log {
52
+ margin-top: 4px;
53
+ color: #fb5547;
54
+ font-weight: 400;
55
+ font-size: 14px;
56
+ }
51
57
  }
@@ -54,9 +54,6 @@ var Text = function Text(props) {
54
54
  if (data.eventId === undefined) {
55
55
  return renderProps(data.attrs[0], 'user');
56
56
  }
57
- if (String(data.eventId) === '-13') {
58
- return renderOrder(data);
59
- }
60
57
  if (String(data.eventId) === '-14') {
61
58
  return renderBusiness(data);
62
59
  }
@@ -125,26 +122,6 @@ var Text = function Text(props) {
125
122
  className: "".concat(classPrefix, "-text-desc-value")
126
123
  }, event.alias || event.name), attrs, timeDimensions, runtimes);
127
124
  }
128
- function renderOrder(condition) {
129
- var periodLabel = {};
130
- if (condition.runPeriod.operator === 'join_time') {
131
- periodLabel.before = '在新增后';
132
- periodLabel.after = '天内';
133
- }
134
- if (condition.runPeriod.operator === 'relative' || condition.runPeriod.operator === 'absolute') {
135
- periodLabel.before = '在';
136
- }
137
- var period = renderPeriod(periodLabel, condition.runPeriod, true);
138
- var frequencyValues = renderFrequencyValues(condition.runTimes.values, condition.runTimes.operator, '次数');
139
- var timeDimensions = renderTimeDimensions(condition.timeDimensions);
140
- var property = renderProperty(condition.attrs, '订单属性');
141
- return /*#__PURE__*/React.createElement("span", {
142
- style: {
143
- backgroundColor: '#fffeeb',
144
- padding: '6px 7px'
145
- }
146
- }, "\u8BA2\u5355\u6570\u636E ", period, timeDimensions, property, frequencyValues);
147
- }
148
125
  function renderBusiness(condition) {
149
126
  var periodLabel = {};
150
127
  if (condition.runPeriod.operator === 'join_time') {
@@ -393,7 +370,7 @@ var Text = function Text(props) {
393
370
  _value$between = value.between,
394
371
  between = _value$between === void 0 ? [] : _value$between;
395
372
  var numOperatorMap = _objectSpread(_objectSpread({}, operatorMap), {}, {
396
- equal: '等于'
373
+ equal: value.webType === 'number' ? '等于' : '是'
397
374
  });
398
375
  var valuesDom = '';
399
376
  var calculateTxt = '';
@@ -218,13 +218,6 @@ var OrConditions = function OrConditions(props) {
218
218
  onChange: onChangeEvent,
219
219
  condition: condition
220
220
  });
221
- } else if (String(conditionData.eventId) === eventIdType.orderData) {
222
- conditionDom = /*#__PURE__*/React.createElement(BusinessCondition, {
223
- label: "\u8BA2\u5355\u6570\u636E",
224
- dataId: id,
225
- onChange: onChangeEvent,
226
- condition: condition
227
- });
228
221
  } else if (util.isNumber(conditionData.eventId)) {
229
222
  conditionDom = /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(EventCondition, {
230
223
  dataId: id,
@@ -93,7 +93,7 @@ var BizUserGroup = function BizUserGroup(_ref) {
93
93
  }
94
94
  }, [groupLoading, tagLoading]);
95
95
  useEffect(function () {
96
- if (!onChange || groupLoading || tagLoading) return;
96
+ if (!onChange || groupLoading || tagLoading || open) return;
97
97
  if (!enableTags) {
98
98
  onChange(chosen === null || chosen === void 0 ? void 0 : chosen.id);
99
99
  return;
@@ -104,7 +104,7 @@ var BizUserGroup = function BizUserGroup(_ref) {
104
104
  layer = _item[2];
105
105
  return layer ? "".concat(tag.id, ":").concat(layer === null || layer === void 0 ? void 0 : layer.layerLabelId) : String(tag.id);
106
106
  }) : chosen === null || chosen === void 0 ? void 0 : chosen.id);
107
- }, [chosen]);
107
+ }, [chosen, open]);
108
108
  var _onClose = function onClose(e, index) {
109
109
  e.stopPropagation();
110
110
  setChosen(function (data) {
@@ -11,7 +11,7 @@ export default (function () {
11
11
  }, /*#__PURE__*/React.createElement(BizUserGroupHeader, {
12
12
  max: 3,
13
13
  enableTags: true,
14
- value: [['4077:685001635528704'], 836, 837],
14
+ value: [0],
15
15
  onChange: function onChange(value) {
16
16
  console.log('>>>>>>>>回传值', value);
17
17
  }
@@ -36,7 +36,8 @@ var CascaderOverlay = function CascaderOverlay(props) {
36
36
  labelFields = props.labelFields,
37
37
  keyFields = props.keyFields,
38
38
  valueFields = props.valueFields,
39
- childFields = props.childFields;
39
+ childFields = props.childFields,
40
+ isOpenLayer = props.isOpenLayer;
40
41
  var timer = useRef(null);
41
42
  var _useState = useState(''),
42
43
  _useState2 = _slicedToArray(_useState, 2),
@@ -162,7 +163,8 @@ var CascaderOverlay = function CascaderOverlay(props) {
162
163
  labelGroup: currentSelect,
163
164
  pageNo: pageNo,
164
165
  pageSize: 20,
165
- labelName: highlightText
166
+ labelName: highlightText,
167
+ isOpenLayer: isOpenLayer
166
168
  }
167
169
  }).then(function (res) {
168
170
  if ((res === null || res === void 0 ? void 0 : res.data) && res.data.results) {
@@ -209,7 +211,7 @@ var CascaderOverlay = function CascaderOverlay(props) {
209
211
  }
210
212
  function onClickTag(data) {
211
213
  setCurrentTag(data);
212
- if ((data === null || data === void 0 ? void 0 : data.labelCreateType) === LabelCreateType.firstAndLastUpdate || (data === null || data === void 0 ? void 0 : data.labelCreateType) === LabelCreateType.fundingSource || (data === null || data === void 0 ? void 0 : data.labelCreateType) === LabelCreateType.eventPreference || (data === null || data === void 0 ? void 0 : data.labelCreateType) === LabelCreateType.sqlCreateTable) {
214
+ if ((data === null || data === void 0 ? void 0 : data.labelCreateType) === LabelCreateType.firstAndLastUpdate || (data === null || data === void 0 ? void 0 : data.labelCreateType) === LabelCreateType.fundingSource || (data === null || data === void 0 ? void 0 : data.labelCreateType) === LabelCreateType.eventPreference || (data === null || data === void 0 ? void 0 : data.labelCreateType) === LabelCreateType.sqlCreateTable || !isOpenLayer) {
213
215
  var newValue = [{
214
216
  id: groupMap[currentSelect].id,
215
217
  labelGroup: currentSelect
@@ -230,7 +232,11 @@ var CascaderOverlay = function CascaderOverlay(props) {
230
232
  });
231
233
  if (_index === -1) {
232
234
  if (currentValue.length >= 20) return;
233
- props.onChange([].concat(_toConsumableArray(currentValue), [newValue]));
235
+ if (isOpenLayer) {
236
+ props.onChange([].concat(_toConsumableArray(currentValue), [newValue]));
237
+ } else {
238
+ props.onChange([newValue]);
239
+ }
234
240
  } else {
235
241
  currentValue.splice(_index, 1);
236
242
  props.onChange(_toConsumableArray(currentValue));
@@ -269,7 +275,7 @@ var CascaderOverlay = function CascaderOverlay(props) {
269
275
  getTagsByGroup(Math.floor(groupMap[currentSelect].children.length / 20) + 1);
270
276
  },
271
277
  onClick: onClickTag
272
- }) : /*#__PURE__*/React.createElement("span", null, "\u6682\u65E0\u6570\u636E")), currentTag && (currentTag === null || currentTag === void 0 ? void 0 : currentTag.labelCreateType) !== LabelCreateType.firstAndLastUpdate && (currentTag === null || currentTag === void 0 ? void 0 : currentTag.labelCreateType) !== LabelCreateType.fundingSource && (currentTag === null || currentTag === void 0 ? void 0 : currentTag.labelCreateType) !== LabelCreateType.eventPreference && (currentTag === null || currentTag === void 0 ? void 0 : currentTag.labelCreateType) !== LabelCreateType.sqlCreateTable && /*#__PURE__*/React.createElement("div", {
278
+ }) : /*#__PURE__*/React.createElement("span", null, "\u6682\u65E0\u6570\u636E")), isOpenLayer && currentTag && (currentTag === null || currentTag === void 0 ? void 0 : currentTag.labelCreateType) !== LabelCreateType.firstAndLastUpdate && (currentTag === null || currentTag === void 0 ? void 0 : currentTag.labelCreateType) !== LabelCreateType.fundingSource && (currentTag === null || currentTag === void 0 ? void 0 : currentTag.labelCreateType) !== LabelCreateType.eventPreference && (currentTag === null || currentTag === void 0 ? void 0 : currentTag.labelCreateType) !== LabelCreateType.sqlCreateTable && /*#__PURE__*/React.createElement("div", {
273
279
  className: "".concat(classPrefix, "-overlay-selections")
274
280
  }, /*#__PURE__*/React.createElement(MultipleCheckPanel, {
275
281
  valueField: valueFields[2],
@@ -299,6 +305,7 @@ CascaderOverlay.defaultProps = {
299
305
  childFields: ['children', 'layers'],
300
306
  keyFields: ['labelGroup', 'id', 'layerLabelId'],
301
307
  labelFields: ['labelGroup', 'labelName', 'layerLabelName'],
302
- valueFields: ['labelGroup', 'id', 'layerLabelId']
308
+ valueFields: ['labelGroup', 'id', 'layerLabelId'],
309
+ isOpenLayer: true
303
310
  };
304
311
  export default CascaderOverlay;
@@ -49,6 +49,7 @@ export default (function () {
49
49
  keyFields: ['labelGroup', 'id', 'layerLabelId'],
50
50
  labelFields: ['labelGroup', 'labelName', 'layerLabelName'],
51
51
  valueFields: ['labelGroup', 'id', 'layerLabelId'],
52
+ isOpenLayer: false,
52
53
  onChange: onChange
53
54
  })));
54
55
  });
@@ -26,7 +26,8 @@ var UserTagsSelect = function UserTagsSelect(props) {
26
26
  labelFields = props.labelFields,
27
27
  childFields = props.childFields,
28
28
  keyFields = props.keyFields,
29
- valueFields = props.valueFields;
29
+ valueFields = props.valueFields,
30
+ isOpenLayer = props.isOpenLayer;
30
31
  var _useState = useState([]),
31
32
  _useState2 = _slicedToArray(_useState, 2),
32
33
  currentValue = _useState2[0],
@@ -42,7 +43,7 @@ var UserTagsSelect = function UserTagsSelect(props) {
42
43
  var pre_text = pre[labelFields[labelFields.length - 2]];
43
44
  var last_text = last[labelFields[labelFields.length - 1]];
44
45
  var res = _objectSpread(_objectSpread({}, last), {}, {
45
- handleText: (pre === null || pre === void 0 ? void 0 : pre.labelCreateType) === 3 || (pre === null || pre === void 0 ? void 0 : pre.labelCreateType) === 6 || (pre === null || pre === void 0 ? void 0 : pre.labelCreateType) === LabelCreateType.sqlCreateTable ? pre_text : "".concat(pre_text, "\uFF1A").concat(last_text)
46
+ handleText: (pre === null || pre === void 0 ? void 0 : pre.labelCreateType) === 3 || (pre === null || pre === void 0 ? void 0 : pre.labelCreateType) === 6 || (pre === null || pre === void 0 ? void 0 : pre.labelCreateType) === LabelCreateType.sqlCreateTable || !isOpenLayer ? pre_text : "".concat(pre_text, "\uFF1A").concat(last_text)
46
47
  });
47
48
  return res;
48
49
  });
@@ -75,6 +76,7 @@ var UserTagsSelect = function UserTagsSelect(props) {
75
76
  keyFields: keyFields,
76
77
  labelFields: labelFields,
77
78
  data: data,
79
+ isOpenLayer: isOpenLayer,
78
80
  onChange: onChange
79
81
  });
80
82
  }
@@ -105,6 +107,7 @@ var UserTagsSelect = function UserTagsSelect(props) {
105
107
  }))));
106
108
  };
107
109
  UserTagsSelect.defaultProps = {
108
- destroyPopupOnHide: false
110
+ destroyPopupOnHide: false,
111
+ isOpenLayer: true
109
112
  };
110
113
  export default UserTagsSelect;
@@ -30,6 +30,7 @@ export declare namespace UserTagsSelectorTypes {
30
30
  defaultCurrent?: string[];
31
31
  onChange: Function;
32
32
  destroyPopupOnHide?: boolean;
33
+ isOpenLayer?: boolean;
33
34
  }
34
35
  interface CascaderOverlayProps {
35
36
  className?: string;
@@ -40,6 +41,7 @@ export declare namespace UserTagsSelectorTypes {
40
41
  valueFields?: string[];
41
42
  currentValue: Value;
42
43
  onChange: (val: Value) => void;
44
+ isOpenLayer?: boolean;
43
45
  }
44
46
  interface Groups {
45
47
  data: any[];
@@ -5,6 +5,8 @@ declare let util: {
5
5
  isArray(obj: any): boolean;
6
6
  isString(obj: any): boolean;
7
7
  isNumber(obj: any): boolean;
8
+ isFloatNumber(str: any): boolean;
9
+ formatNumberWithCommas(number: any): any;
8
10
  isDate(obj: any): boolean;
9
11
  isFunction(obj: any): boolean;
10
12
  isBlob(obj: any): boolean;
@@ -34,5 +36,6 @@ declare let util: {
34
36
  transformRequest(param: {
35
37
  [prop: string]: any;
36
38
  }): string;
39
+ isMobile(): boolean;
37
40
  };
38
41
  export default util;
package/es/utils/util.js CHANGED
@@ -16,6 +16,12 @@ var util = {
16
16
  isNumber: function isNumber(obj) {
17
17
  return this.type(obj) === '[object Number]';
18
18
  },
19
+ isFloatNumber: function isFloatNumber(str) {
20
+ return /^-?\d+(\.\d+)?$/.test(str);
21
+ },
22
+ formatNumberWithCommas: function formatNumberWithCommas(number) {
23
+ return number.toLocaleString();
24
+ },
19
25
  isDate: function isDate(obj) {
20
26
  return this.type(obj) === '[object Date]';
21
27
  },
@@ -173,6 +179,10 @@ var util = {
173
179
  arr.push("".concat(key, "=").concat(encodeURIComponent(param[key])));
174
180
  }
175
181
  return arr.join('&');
182
+ },
183
+ isMobile: function isMobile() {
184
+ var userAgent = navigator.userAgent || navigator.vendor;
185
+ return /android|webos|iphone|ipad|ipod|blackberry|iemobile|opera mini/i.test(userAgent);
176
186
  }
177
187
  };
178
188
  export default util;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zgfe/business-lib",
3
- "version": "1.2.58-ljy.0",
3
+ "version": "1.2.70-hxd.1",
4
4
  "module": "es/index.js",
5
5
  "typings": "es/index.d.ts",
6
6
  "files": [
@@ -31,8 +31,6 @@
31
31
  "@types/qs": "^6.9.7",
32
32
  "axios": "^0.26.1",
33
33
  "babel-plugin-import": "^1.13.3",
34
- "echarts": "^5.3.2",
35
- "echarts-for-react": "^3.0.2",
36
34
  "lerna": "^4.0.0",
37
35
  "rc-virtual-list": "^3.4.8",
38
36
  "react-infinite-scroll-component": "^6.1.0",
@@ -47,6 +45,8 @@
47
45
  "@umijs/test": "^3.0.5",
48
46
  "antd": "4.24.16",
49
47
  "dumi": "^1.1.0",
48
+ "echarts": "^5.3.2",
49
+ "echarts-for-react": "^3.0.2",
50
50
  "father-build": "^1.17.2",
51
51
  "gh-pages": "^3.0.0",
52
52
  "lint-staged": "^10.0.7",
@@ -55,7 +55,7 @@
55
55
  "react": "^16.12.0 || ^17.0.0",
56
56
  "yorkie": "^2.0.0"
57
57
  },
58
- "gitHead": "9e631587e01af190d42323d48d2158f04149afca",
58
+ "gitHead": "66a5af78d07673c2ca148d3ee25b0a24624ea31e",
59
59
  "gitHooks": {
60
60
  "pre-commit": "lint-staged"
61
61
  }