@zgfe/business-lib 1.2.55-plat.5 → 1.2.55
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/es/assets/iconfont/demo_index.html +3 -3
- package/es/assets/iconfont/iconfont.css +3 -3
- package/es/assets/iconfont/iconfont.ttf +0 -0
- package/es/assets/iconfont/iconfont.woff +0 -0
- package/es/assets/iconfont/iconfont.woff2 +0 -0
- package/es/chart/demo/data/data.d.ts +2 -0
- package/es/chart/demo/data/data.js +5 -37
- package/es/chart/demo/line_bar_stack.js +0 -1
- package/es/chart/index.js +14 -1
- package/es/chart/styles/index.less +45 -0
- package/es/chart/types.d.ts +1 -0
- package/es/chart/util/chartOptionConfig.js +12 -0
- package/es/chart/util/formatData.js +3 -1
- package/es/chart/util/formatOption.js +21 -11
- package/es/constants/apis.d.ts +0 -1
- package/es/constants/apis.js +1 -2
- package/es/platformSelector/index.js +4 -5
- package/es/platformSelector/styles/index.less +0 -4
- package/es/platformSelector/util.d.ts +1 -1
- package/es/platformSelector/util.js +1 -8
- package/es/userCondition/conditions/textDesc.js +1 -1
- package/es/userTagsSelector/cascaderOverlay.js +6 -13
- package/es/userTagsSelector/index.js +3 -6
- package/es/userTagsSelector/types.d.ts +0 -2
- package/package.json +2 -2
|
@@ -1398,9 +1398,9 @@
|
|
|
1398
1398
|
<pre><code class="language-css"
|
|
1399
1399
|
>@font-face {
|
|
1400
1400
|
font-family: 'bsicon';
|
|
1401
|
-
src: url('iconfont.woff2?t=
|
|
1402
|
-
url('iconfont.woff?t=
|
|
1403
|
-
url('iconfont.ttf?t=
|
|
1401
|
+
src: url('iconfont.woff2?t=1724914693920') format('woff2'),
|
|
1402
|
+
url('iconfont.woff?t=1724914693920') format('woff'),
|
|
1403
|
+
url('iconfont.ttf?t=1724914693920') format('truetype');
|
|
1404
1404
|
}
|
|
1405
1405
|
</code></pre>
|
|
1406
1406
|
<h3 id="-iconfont-">第二步:定义使用 iconfont 的样式</h3>
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
@font-face {
|
|
2
2
|
font-family: "bsicon"; /* Project id 2545884 */
|
|
3
|
-
src: url('iconfont.woff2?t=
|
|
4
|
-
url('iconfont.woff?t=
|
|
5
|
-
url('iconfont.ttf?t=
|
|
3
|
+
src: url('iconfont.woff2?t=1724914693920') format('woff2'),
|
|
4
|
+
url('iconfont.woff?t=1724914693920') format('woff'),
|
|
5
|
+
url('iconfont.ttf?t=1724914693920') format('truetype');
|
|
6
6
|
}
|
|
7
7
|
|
|
8
8
|
.bsicon {
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -1,49 +1,17 @@
|
|
|
1
1
|
export default {
|
|
2
|
-
xAxis: ['2022-12-01', '2022-12-02', '2022-12-03', '2022-12-04', '2022-12-05', '2022-12-06', '2022-12-07', '2022-12-08', '2022-12-09', '2022-12-10', '2022-12-11', '
|
|
2
|
+
xAxis: ['2022-12-01', '2022-12-02', '2022-12-03', '2022-12-04', '2022-12-05', '2022-12-06', '2022-12-07', '2022-12-08', '2022-12-09', '2022-12-10', '2022-12-11', '2024-08-19', '2024-09-16', '2024-10-16'],
|
|
3
3
|
series: [{
|
|
4
|
-
names: ['付款成功付款成功付款成功付款成功付款成功付款成功付款成功付款成功付款成功付款成功付款成功付款成功付款成功付款成功'],
|
|
5
|
-
values: [26, 27, 43, 44, 40, 34, 33, 33, 34, 24, 30, 31, 31, 38],
|
|
6
|
-
orderNum: 1
|
|
7
|
-
}, {
|
|
8
|
-
names: ['注册-发送手机验证码'],
|
|
9
|
-
values: [11, 10, 7, 5, 13, 18, 14, 17, 11, 6, 10, 12, 15, 10],
|
|
10
|
-
orderNum: 1
|
|
11
|
-
}, {
|
|
12
|
-
names: ['搜索商品'],
|
|
13
|
-
values: [75, 68, 86, 80, 87, 71, 72, 81, 77, 74, 78, 76, 76, 79],
|
|
14
|
-
orderNum: 2
|
|
15
|
-
}, {
|
|
16
4
|
names: ['pv'],
|
|
17
5
|
values: [104, 89, 109, 103, 112, 93, 87, 101, 101, 97, 102, 110, 106, 98],
|
|
6
|
+
minValues: [null, null, null, null, null, null, null, null, null, null, null, 102, 0, 1, 2],
|
|
7
|
+
maxValues: [null, null, null, null, null, null, null, null, null, null, null, 666, 1111, 2222],
|
|
18
8
|
orderNum: 3
|
|
19
9
|
}, {
|
|
20
10
|
names: ['申请退货2'],
|
|
21
11
|
values: [5, 11, 14, 9, 8, 14, 9, 10, 12, 12, 14, 16, 12, 10],
|
|
12
|
+
minValues: [null, null, null, null, null, null, null, null, null, null, null, null, 44, 55, 66],
|
|
13
|
+
maxValues: [null, null, null, null, null, null, null, null, null, null, null, null, 888, 5555],
|
|
22
14
|
orderNum: 4
|
|
23
|
-
}, {
|
|
24
|
-
names: ['搜索商品'],
|
|
25
|
-
values: [75, 68, 86, 80, 87, 71, 72, 81, 77, 74, 78, 76, 76, 79],
|
|
26
|
-
orderNum: 5
|
|
27
|
-
}, {
|
|
28
|
-
names: ['付款成功11付款成功付款成功付款成功付款成功付款成功付款成功付款成功付款成功付款成功付款成功付款成功付款成功付款成功'],
|
|
29
|
-
values: [26, 27, 43, 44, 40, 34, 33, 33, 34, 24, 30, 31, 31, 38],
|
|
30
|
-
orderNum: 1
|
|
31
|
-
}, {
|
|
32
|
-
names: ['查看商品详情'],
|
|
33
|
-
values: [122, 107, 132, 113, 133, 115, 106, 127, 132, 117, 119, 123, 119, 117],
|
|
34
|
-
orderNum: 2
|
|
35
|
-
}, {
|
|
36
|
-
names: ['scroll'],
|
|
37
|
-
values: [98, 96, 106, 109, 113, 105, 91, 111, 99, 99, 104, 108, 116, 92],
|
|
38
|
-
orderNum: 3
|
|
39
|
-
}, {
|
|
40
|
-
names: ['click'],
|
|
41
|
-
values: [108, 102, 111, 90, 111, 105, 91, 129, 117, 101, 109, 109, 105, 96],
|
|
42
|
-
orderNum: 4
|
|
43
|
-
}, {
|
|
44
|
-
names: ['申请退货'],
|
|
45
|
-
values: [5, 11, 14, 9, 8, 14, 9, 10, 12, 12, 14, 16, 12, 10],
|
|
46
|
-
orderNum: 5
|
|
47
15
|
}]
|
|
48
16
|
};
|
|
49
17
|
export var barData = {
|
|
@@ -146,7 +146,6 @@ export default (function () {
|
|
|
146
146
|
htmlArray.push("<div class=\"biz-chart-tooltip-item\">\n <div class=\"biz-chart-tooltip-content\">\n <span class=\"biz-tooltip-order\" style=\"background:".concat(params.color, "\"></span>\n <div class=\"biz-tooltip-name\">").concat(params.seriesName, "</div>\n </div> \n <span class=\"biz-chart-tooltip-value\">").concat(params.value, "</span>\n </div>"));
|
|
147
147
|
return htmlArray.join('');
|
|
148
148
|
};
|
|
149
|
-
console.log('colorList', colorList);
|
|
150
149
|
return /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement(BizChart, {
|
|
151
150
|
showList: showList,
|
|
152
151
|
data: data,
|
package/es/chart/index.js
CHANGED
|
@@ -43,7 +43,8 @@ var BizChart = /*#__PURE__*/React.forwardRef(function (props, ref) {
|
|
|
43
43
|
isHideLegend = props.isHideLegend,
|
|
44
44
|
tooltipTrigger = props.tooltipTrigger,
|
|
45
45
|
muit_yAxis = props.muit_yAxis,
|
|
46
|
-
unContainLabel = props.unContainLabel
|
|
46
|
+
unContainLabel = props.unContainLabel,
|
|
47
|
+
markArea = props.markArea;
|
|
47
48
|
var _useState = useState({}),
|
|
48
49
|
_useState2 = _slicedToArray(_useState, 2),
|
|
49
50
|
chartOption = _useState2[0],
|
|
@@ -71,6 +72,18 @@ var BizChart = /*#__PURE__*/React.forwardRef(function (props, ref) {
|
|
|
71
72
|
option.series.forEach(function (series, seriesIndex) {
|
|
72
73
|
var dashedItem = addDashedSeries(series, index - 1);
|
|
73
74
|
dashedItem.itemStyle.normal.color = dashedItem.lineStyle.normal.color = option.color[seriesIndex];
|
|
75
|
+
if (markArea) {
|
|
76
|
+
dashedItem.markArea = {
|
|
77
|
+
itemStyle: {
|
|
78
|
+
color: 'rgba(22, 93, 255, 0.08)'
|
|
79
|
+
},
|
|
80
|
+
data: [[{
|
|
81
|
+
xAxis: option.xAxis.data[index]
|
|
82
|
+
}, {
|
|
83
|
+
xAxis: option.xAxis.data[option.xAxis.data.length - 1]
|
|
84
|
+
}]]
|
|
85
|
+
};
|
|
86
|
+
}
|
|
74
87
|
dashedSeries.push(dashedItem);
|
|
75
88
|
});
|
|
76
89
|
option.series = option.series.concat(dashedSeries);
|
|
@@ -65,4 +65,49 @@
|
|
|
65
65
|
font-weight: 500;
|
|
66
66
|
}
|
|
67
67
|
}
|
|
68
|
+
|
|
69
|
+
.biz-chart-tooltip-item-new {
|
|
70
|
+
min-height: @height-sm;
|
|
71
|
+
margin-bottom: 4px;
|
|
72
|
+
padding: 0px @padding-xs;
|
|
73
|
+
font-size: @font-size-sm;
|
|
74
|
+
background: @white;
|
|
75
|
+
border-radius: @border-radius-small;
|
|
76
|
+
box-shadow: @box-shadow-small;
|
|
77
|
+
.biz-chart-tooltip-content {
|
|
78
|
+
display: flex;
|
|
79
|
+
align-items: center;
|
|
80
|
+
color: @text-color-secondary;
|
|
81
|
+
|
|
82
|
+
.biz-tooltip-marker {
|
|
83
|
+
width: 8px;
|
|
84
|
+
height: 8px;
|
|
85
|
+
margin-right: @margin-xs;
|
|
86
|
+
border-radius: 50%;
|
|
87
|
+
}
|
|
88
|
+
.biz-tooltip-order {
|
|
89
|
+
display: flex;
|
|
90
|
+
align-items: center;
|
|
91
|
+
justify-content: center;
|
|
92
|
+
width: 12.8px;
|
|
93
|
+
height: 12.8px;
|
|
94
|
+
margin-right: @margin-xs;
|
|
95
|
+
color: #fff;
|
|
96
|
+
font-weight: 500;
|
|
97
|
+
font-size: 8.96px;
|
|
98
|
+
background: #457dff;
|
|
99
|
+
border-radius: 50%;
|
|
100
|
+
}
|
|
101
|
+
.biz-tooltip-name {
|
|
102
|
+
max-width: 300px;
|
|
103
|
+
white-space: pre-wrap;
|
|
104
|
+
word-wrap: break-word;
|
|
105
|
+
word-break: break-all;
|
|
106
|
+
}
|
|
107
|
+
}
|
|
108
|
+
&-value {
|
|
109
|
+
font-weight: 700;
|
|
110
|
+
// font-size: 14px;
|
|
111
|
+
}
|
|
112
|
+
}
|
|
68
113
|
}
|
package/es/chart/types.d.ts
CHANGED
|
@@ -161,6 +161,7 @@ export var getChartOption = function getChartOption(chartType, data) {
|
|
|
161
161
|
yAxis.minInterval = 1;
|
|
162
162
|
}
|
|
163
163
|
var series = [];
|
|
164
|
+
var seriesObject = {};
|
|
164
165
|
if (chartType === 'bar') {
|
|
165
166
|
seriesItem.barMaxWidth = 40;
|
|
166
167
|
}
|
|
@@ -174,6 +175,9 @@ export var getChartOption = function getChartOption(chartType, data) {
|
|
|
174
175
|
yAxisIndex: item.yAxisIndex
|
|
175
176
|
} : {});
|
|
176
177
|
});
|
|
178
|
+
series.map(function (item) {
|
|
179
|
+
seriesObject[item.name] = item;
|
|
180
|
+
});
|
|
177
181
|
} else {
|
|
178
182
|
series = [_objectSpread(_objectSpread(_objectSpread({
|
|
179
183
|
name: seriesName || '',
|
|
@@ -189,6 +193,14 @@ export var getChartOption = function getChartOption(chartType, data) {
|
|
|
189
193
|
tooltip.axisPointer = tooltip.axisPointer || {};
|
|
190
194
|
tooltip.axisPointer.type = chartType === 'bar' || chartType === 'line_bar' || chartType === 'muit_y' ? 'shadow' : 'line';
|
|
191
195
|
tooltip.formatter = function (params) {
|
|
196
|
+
if (Object.keys(seriesObject).length > 0) {
|
|
197
|
+
params.map(function (item) {
|
|
198
|
+
var _minValues = seriesObject[item.seriesName].minValues;
|
|
199
|
+
var _mixValues = seriesObject[item.seriesName].maxValues;
|
|
200
|
+
item.minValues = _minValues ? _minValues[item.dataIndex] : null;
|
|
201
|
+
item.maxValues = _mixValues ? _mixValues[item.dataIndex] : null;
|
|
202
|
+
});
|
|
203
|
+
}
|
|
192
204
|
return tooltipFormatter ? tooltipFormatter(params) : tooltip.trigger === 'item' ? tooltipFormatterItemDefault(params, data.resultFormatMap, unit) : tooltipFormatterDefault(params, data.resultFormatMap, unit);
|
|
193
205
|
};
|
|
194
206
|
if (legendPosition === 'top') {
|
|
@@ -66,7 +66,9 @@ export var formatChartData = function formatChartData(data, showAll, showList, r
|
|
|
66
66
|
} else {
|
|
67
67
|
sData.push(_objectSpread(_objectSpread({
|
|
68
68
|
name: showName,
|
|
69
|
-
data: seriesItem.values
|
|
69
|
+
data: seriesItem.values,
|
|
70
|
+
minValues: seriesItem === null || seriesItem === void 0 ? void 0 : seriesItem.minValues,
|
|
71
|
+
maxValues: seriesItem === null || seriesItem === void 0 ? void 0 : seriesItem.maxValues
|
|
70
72
|
}, seriesItem.stack ? {
|
|
71
73
|
stack: seriesItem.stack
|
|
72
74
|
} : {}), {}, {
|
|
@@ -20,16 +20,22 @@ var tooltipFormatterDefault = function tooltipFormatterDefault(params, resultFor
|
|
|
20
20
|
return;
|
|
21
21
|
}
|
|
22
22
|
seriesMap[item.seriesName] = item.value;
|
|
23
|
-
var
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
23
|
+
var unitHandle = function unitHandle(_value) {
|
|
24
|
+
var _data = _value;
|
|
25
|
+
if (item.seriesName.indexOf('CTR') > -1) {
|
|
26
|
+
_data += '%';
|
|
27
|
+
} else if (resultFormatMap && resultFormatMap[item.seriesName] && /percent/.test(resultFormatMap[item.seriesName])) {
|
|
28
|
+
_data = util.toThousands(_data) + '%';
|
|
29
|
+
} else if (unit && unit === 'time') {
|
|
30
|
+
_data = util.timeFormat(_data, 'hhhmmmsss', 1);
|
|
31
|
+
} else {
|
|
32
|
+
_data = util.toThousands(_data) + (unit || '');
|
|
33
|
+
}
|
|
34
|
+
return _data;
|
|
35
|
+
};
|
|
36
|
+
var lineLabel = unitHandle(item.value);
|
|
37
|
+
var minValues = (item.minValues || item.minValues === 0) && unitHandle(item.minValues);
|
|
38
|
+
var maxValues = (item.maxValues || item.maxValues === 0) && unitHandle(item.maxValues);
|
|
33
39
|
var name = item.seriesName.trim();
|
|
34
40
|
if (item.seriesType === 'bar' && params.length === 1 && !name) {
|
|
35
41
|
name = (item.data && item.data.label ? item.data.label : item.name).trim();
|
|
@@ -37,7 +43,11 @@ var tooltipFormatterDefault = function tooltipFormatterDefault(params, resultFor
|
|
|
37
43
|
var nameArr = name.split('|:|');
|
|
38
44
|
name = nameArr[0];
|
|
39
45
|
var orderNum = nameArr[1];
|
|
40
|
-
|
|
46
|
+
if (item.minValues === null && item.maxValues === null) {
|
|
47
|
+
htmlArray.push("<div class=\"biz-chart-tooltip-item\">\n <div class=\"biz-chart-tooltip-content\">\n <span class=\"".concat(orderNum ? 'biz-tooltip-order' : 'biz-tooltip-marker', "\" style=\"background:").concat(item.color, "\">").concat(orderNum || '', "</span>\n <div class=\"biz-tooltip-name\">").concat(name, "</div>\n </div> \n <span class=\"biz-chart-tooltip-value\">").concat(lineLabel, "</span>\n </div>"));
|
|
48
|
+
} else {
|
|
49
|
+
htmlArray.push("<div class=\"biz-chart-tooltip-item-new\">\n <div class=\"biz-chart-tooltip-content\">\n <span class=\"".concat(orderNum ? 'biz-tooltip-order' : 'biz-tooltip-marker', "\" style=\"background:").concat(item.color, "\">").concat(orderNum || '', "</span>\n <div class=\"biz-tooltip-name\">").concat(name, "</div>\n </div> \n <div>\n <div>\n <span>\u9884\u6D4B\u503C\uFF1A</span>\n <span class=\"biz-chart-tooltip-item-new-value\">").concat(lineLabel, "</span>\n </div>\n <div>\n <span>\u9884\u6D4B\u6700\u5927\u503C\uFF1A</span>\n <span class=\"biz-chart-tooltip-item-new-value\">").concat(maxValues, "</span>\n </div>\n <div>\n <span>\u9884\u6D4B\u6700\u5C0F\u503C\uFF1A</span>\n <span class=\"biz-chart-tooltip-item-new-value\">").concat(minValues, "</span>\n </div>\n </div>\n </div>"));
|
|
50
|
+
}
|
|
41
51
|
});
|
|
42
52
|
return htmlArray.join('');
|
|
43
53
|
};
|
package/es/constants/apis.d.ts
CHANGED
package/es/constants/apis.js
CHANGED
|
@@ -25,7 +25,6 @@ var Apis = {
|
|
|
25
25
|
querySubjectList: '/zg/web/v2/analysisSubject/queryAllSubject',
|
|
26
26
|
queryPanels: '/zg/web/v2/apppanel/panels',
|
|
27
27
|
queryMetaDatasetList: '/zg/web/v2/meta/dataset/list',
|
|
28
|
-
queryDatasetTableNames: '/zg/web/cdp/dataset/manager/datasetList'
|
|
29
|
-
queryPlatformList: '/zg/web/v2/data/dynamicPlatformByAppid'
|
|
28
|
+
queryDatasetTableNames: '/zg/web/cdp/dataset/manager/datasetList'
|
|
30
29
|
};
|
|
31
30
|
export default Apis;
|
|
@@ -6,8 +6,8 @@ function _iterableToArrayLimit(arr, i) { var _i = null == arr ? null : "undefine
|
|
|
6
6
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
7
7
|
import React, { useState, useEffect } from 'react';
|
|
8
8
|
import { BizSelect } from '@zgfe/business-lib';
|
|
9
|
+
import { platformOption } from './util';
|
|
9
10
|
import './styles/index.less';
|
|
10
|
-
import { platformOptionUtil } from './util';
|
|
11
11
|
var BizPlatformSelector = function BizPlatformSelector(props) {
|
|
12
12
|
var classPrefix = 'biz-platform-selector';
|
|
13
13
|
var _useState = useState(),
|
|
@@ -16,19 +16,18 @@ var BizPlatformSelector = function BizPlatformSelector(props) {
|
|
|
16
16
|
setCurrentValue = _useState2[1];
|
|
17
17
|
useEffect(function () {
|
|
18
18
|
if (props.value) {
|
|
19
|
-
var selectValue =
|
|
19
|
+
var selectValue = platformOption.find(function (item) {
|
|
20
20
|
return item.key === props.value;
|
|
21
21
|
});
|
|
22
|
-
setCurrentValue(selectValue ||
|
|
22
|
+
setCurrentValue(selectValue || platformOption[0]);
|
|
23
23
|
}
|
|
24
24
|
}, [props.value]);
|
|
25
|
-
useEffect(function () {}, []);
|
|
26
25
|
return /*#__PURE__*/React.createElement("div", {
|
|
27
26
|
className: classPrefix
|
|
28
27
|
}, /*#__PURE__*/React.createElement(BizSelect, {
|
|
29
28
|
className: "".concat(classPrefix, "-select"),
|
|
30
29
|
overlayClassName: "".concat(classPrefix, "-select-overlay"),
|
|
31
|
-
options: props.valueOption && props.valueOption.length ? props.valueOption :
|
|
30
|
+
options: props.valueOption && props.valueOption.length ? props.valueOption : platformOption,
|
|
32
31
|
overlayWidth: 134,
|
|
33
32
|
keyField: "key",
|
|
34
33
|
labelField: "value",
|
|
@@ -8,10 +8,6 @@
|
|
|
8
8
|
.biz-select-handle-content .biz-select-handle-icon .bsicon {
|
|
9
9
|
color: #9aa1a9;
|
|
10
10
|
}
|
|
11
|
-
.biz-select-handle-content-label {
|
|
12
|
-
display: flex;
|
|
13
|
-
align-items: center;
|
|
14
|
-
}
|
|
15
11
|
}
|
|
16
12
|
}
|
|
17
13
|
.biz-platform-selector-select-overlay .biz-select-list-panel .biz-select-option {
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import { platItemProp } from './types';
|
|
2
|
-
export declare const
|
|
2
|
+
export declare const platformOption: platItemProp[];
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { IconFont } from '@zgfe/business-lib';
|
|
3
|
-
export var
|
|
3
|
+
export var platformOption = [{
|
|
4
4
|
key: 0,
|
|
5
5
|
value: '全部平台'
|
|
6
6
|
}, {
|
|
@@ -38,13 +38,6 @@ export var platformOptionUtil = [{
|
|
|
38
38
|
type: "fuwuqi",
|
|
39
39
|
size: 16
|
|
40
40
|
})
|
|
41
|
-
}, {
|
|
42
|
-
key: 6,
|
|
43
|
-
value: '鸿蒙',
|
|
44
|
-
icon: /*#__PURE__*/React.createElement(IconFont, {
|
|
45
|
-
type: "hongmeng",
|
|
46
|
-
size: 16
|
|
47
|
-
})
|
|
48
41
|
}, {
|
|
49
42
|
key: -1,
|
|
50
43
|
value: '其他'
|
|
@@ -393,7 +393,7 @@ var Text = function Text(props) {
|
|
|
393
393
|
_value$between = value.between,
|
|
394
394
|
between = _value$between === void 0 ? [] : _value$between;
|
|
395
395
|
var numOperatorMap = _objectSpread(_objectSpread({}, operatorMap), {}, {
|
|
396
|
-
equal:
|
|
396
|
+
equal: '等于'
|
|
397
397
|
});
|
|
398
398
|
var valuesDom = '';
|
|
399
399
|
var calculateTxt = '';
|
|
@@ -36,8 +36,7 @@ var CascaderOverlay = function CascaderOverlay(props) {
|
|
|
36
36
|
labelFields = props.labelFields,
|
|
37
37
|
keyFields = props.keyFields,
|
|
38
38
|
valueFields = props.valueFields,
|
|
39
|
-
childFields = props.childFields
|
|
40
|
-
isOpenLayer = props.isOpenLayer;
|
|
39
|
+
childFields = props.childFields;
|
|
41
40
|
var timer = useRef(null);
|
|
42
41
|
var _useState = useState(''),
|
|
43
42
|
_useState2 = _slicedToArray(_useState, 2),
|
|
@@ -163,8 +162,7 @@ var CascaderOverlay = function CascaderOverlay(props) {
|
|
|
163
162
|
labelGroup: currentSelect,
|
|
164
163
|
pageNo: pageNo,
|
|
165
164
|
pageSize: 20,
|
|
166
|
-
labelName: highlightText
|
|
167
|
-
isOpenLayer: isOpenLayer || true
|
|
165
|
+
labelName: highlightText
|
|
168
166
|
}
|
|
169
167
|
}).then(function (res) {
|
|
170
168
|
if ((res === null || res === void 0 ? void 0 : res.data) && res.data.results) {
|
|
@@ -211,7 +209,7 @@ var CascaderOverlay = function CascaderOverlay(props) {
|
|
|
211
209
|
}
|
|
212
210
|
function onClickTag(data) {
|
|
213
211
|
setCurrentTag(data);
|
|
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
|
|
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) {
|
|
215
213
|
var newValue = [{
|
|
216
214
|
id: groupMap[currentSelect].id,
|
|
217
215
|
labelGroup: currentSelect
|
|
@@ -232,11 +230,7 @@ var CascaderOverlay = function CascaderOverlay(props) {
|
|
|
232
230
|
});
|
|
233
231
|
if (_index === -1) {
|
|
234
232
|
if (currentValue.length >= 20) return;
|
|
235
|
-
|
|
236
|
-
props.onChange([].concat(_toConsumableArray(currentValue), [newValue]));
|
|
237
|
-
} else {
|
|
238
|
-
props.onChange([newValue]);
|
|
239
|
-
}
|
|
233
|
+
props.onChange([].concat(_toConsumableArray(currentValue), [newValue]));
|
|
240
234
|
} else {
|
|
241
235
|
currentValue.splice(_index, 1);
|
|
242
236
|
props.onChange(_toConsumableArray(currentValue));
|
|
@@ -275,7 +269,7 @@ var CascaderOverlay = function CascaderOverlay(props) {
|
|
|
275
269
|
getTagsByGroup(Math.floor(groupMap[currentSelect].children.length / 20) + 1);
|
|
276
270
|
},
|
|
277
271
|
onClick: onClickTag
|
|
278
|
-
}) : /*#__PURE__*/React.createElement("span", null, "\u6682\u65E0\u6570\u636E")),
|
|
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", {
|
|
279
273
|
className: "".concat(classPrefix, "-overlay-selections")
|
|
280
274
|
}, /*#__PURE__*/React.createElement(MultipleCheckPanel, {
|
|
281
275
|
valueField: valueFields[2],
|
|
@@ -305,7 +299,6 @@ CascaderOverlay.defaultProps = {
|
|
|
305
299
|
childFields: ['children', 'layers'],
|
|
306
300
|
keyFields: ['labelGroup', 'id', 'layerLabelId'],
|
|
307
301
|
labelFields: ['labelGroup', 'labelName', 'layerLabelName'],
|
|
308
|
-
valueFields: ['labelGroup', 'id', 'layerLabelId']
|
|
309
|
-
isOpenLayer: true
|
|
302
|
+
valueFields: ['labelGroup', 'id', 'layerLabelId']
|
|
310
303
|
};
|
|
311
304
|
export default CascaderOverlay;
|
|
@@ -26,8 +26,7 @@ var UserTagsSelect = function UserTagsSelect(props) {
|
|
|
26
26
|
labelFields = props.labelFields,
|
|
27
27
|
childFields = props.childFields,
|
|
28
28
|
keyFields = props.keyFields,
|
|
29
|
-
valueFields = props.valueFields
|
|
30
|
-
isOpenLayer = props.isOpenLayer;
|
|
29
|
+
valueFields = props.valueFields;
|
|
31
30
|
var _useState = useState([]),
|
|
32
31
|
_useState2 = _slicedToArray(_useState, 2),
|
|
33
32
|
currentValue = _useState2[0],
|
|
@@ -43,7 +42,7 @@ var UserTagsSelect = function UserTagsSelect(props) {
|
|
|
43
42
|
var pre_text = pre[labelFields[labelFields.length - 2]];
|
|
44
43
|
var last_text = last[labelFields[labelFields.length - 1]];
|
|
45
44
|
var res = _objectSpread(_objectSpread({}, last), {}, {
|
|
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
|
|
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)
|
|
47
46
|
});
|
|
48
47
|
return res;
|
|
49
48
|
});
|
|
@@ -76,7 +75,6 @@ var UserTagsSelect = function UserTagsSelect(props) {
|
|
|
76
75
|
keyFields: keyFields,
|
|
77
76
|
labelFields: labelFields,
|
|
78
77
|
data: data,
|
|
79
|
-
isOpenLayer: isOpenLayer,
|
|
80
78
|
onChange: onChange
|
|
81
79
|
});
|
|
82
80
|
}
|
|
@@ -107,7 +105,6 @@ var UserTagsSelect = function UserTagsSelect(props) {
|
|
|
107
105
|
}))));
|
|
108
106
|
};
|
|
109
107
|
UserTagsSelect.defaultProps = {
|
|
110
|
-
destroyPopupOnHide: false
|
|
111
|
-
isOpenLayer: true
|
|
108
|
+
destroyPopupOnHide: false
|
|
112
109
|
};
|
|
113
110
|
export default UserTagsSelect;
|
|
@@ -30,7 +30,6 @@ export declare namespace UserTagsSelectorTypes {
|
|
|
30
30
|
defaultCurrent?: string[];
|
|
31
31
|
onChange: Function;
|
|
32
32
|
destroyPopupOnHide?: boolean;
|
|
33
|
-
isOpenLayer?: boolean;
|
|
34
33
|
}
|
|
35
34
|
interface CascaderOverlayProps {
|
|
36
35
|
className?: string;
|
|
@@ -41,7 +40,6 @@ export declare namespace UserTagsSelectorTypes {
|
|
|
41
40
|
valueFields?: string[];
|
|
42
41
|
currentValue: Value;
|
|
43
42
|
onChange: (val: Value) => void;
|
|
44
|
-
isOpenLayer?: boolean;
|
|
45
43
|
}
|
|
46
44
|
interface Groups {
|
|
47
45
|
data: any[];
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@zgfe/business-lib",
|
|
3
|
-
"version": "1.2.55
|
|
3
|
+
"version": "1.2.55",
|
|
4
4
|
"module": "es/index.js",
|
|
5
5
|
"typings": "es/index.d.ts",
|
|
6
6
|
"files": [
|
|
@@ -55,7 +55,7 @@
|
|
|
55
55
|
"react": "^16.12.0 || ^17.0.0",
|
|
56
56
|
"yorkie": "^2.0.0"
|
|
57
57
|
},
|
|
58
|
-
"gitHead": "
|
|
58
|
+
"gitHead": "25944340f9d8fbe6a2b01b0be4ba672abb86a7f7",
|
|
59
59
|
"gitHooks": {
|
|
60
60
|
"pre-commit": "lint-staged"
|
|
61
61
|
}
|