@vtx/modals2 2.8.7 → 2.8.8
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/lib/index.js +7 -0
- package/lib/index.js.map +1 -1
- package/lib/typings.d.ts +0 -1
- package/lib/vm-image-text/index.js +8 -2
- package/lib/vm-image-text/index.js.map +1 -1
- package/lib/vtx-base-modal/index.js +10 -1
- package/lib/vtx-base-modal/index.js.map +1 -1
- package/lib/vtx-cc-cp-modal/api.js +306 -0
- package/lib/vtx-cc-cp-modal/api.js.map +1 -0
- package/lib/vtx-cc-cp-modal/components/AlarmInfo/AlarmRecord.js +153 -0
- package/lib/vtx-cc-cp-modal/components/AlarmInfo/AlarmRecord.js.map +1 -0
- package/lib/vtx-cc-cp-modal/components/AlarmInfo/MonthTrend.js +104 -0
- package/lib/vtx-cc-cp-modal/components/AlarmInfo/MonthTrend.js.map +1 -0
- package/lib/vtx-cc-cp-modal/components/AlarmInfo/Summary.js +135 -0
- package/lib/vtx-cc-cp-modal/components/AlarmInfo/Summary.js.map +1 -0
- package/lib/vtx-cc-cp-modal/components/AlarmInfo/index.css +116 -0
- package/lib/vtx-cc-cp-modal/components/AlarmInfo/index.js +35 -0
- package/lib/vtx-cc-cp-modal/components/AlarmInfo/index.js.map +1 -0
- package/lib/vtx-cc-cp-modal/components/AlarmInfo/index.less +104 -0
- package/lib/vtx-cc-cp-modal/components/BaseInfo/AllWork.js +77 -0
- package/lib/vtx-cc-cp-modal/components/BaseInfo/AllWork.js.map +1 -0
- package/lib/vtx-cc-cp-modal/components/BaseInfo/Info.js +45 -0
- package/lib/vtx-cc-cp-modal/components/BaseInfo/Info.js.map +1 -0
- package/lib/vtx-cc-cp-modal/components/BaseInfo/Rules.js +49 -0
- package/lib/vtx-cc-cp-modal/components/BaseInfo/Rules.js.map +1 -0
- package/lib/vtx-cc-cp-modal/components/BaseInfo/SyRecord.js +126 -0
- package/lib/vtx-cc-cp-modal/components/BaseInfo/SyRecord.js.map +1 -0
- package/lib/vtx-cc-cp-modal/components/BaseInfo/index.css +102 -0
- package/lib/vtx-cc-cp-modal/components/BaseInfo/index.js +67 -0
- package/lib/vtx-cc-cp-modal/components/BaseInfo/index.js.map +1 -0
- package/lib/vtx-cc-cp-modal/components/BaseInfo/index.less +89 -0
- package/lib/vtx-cc-cp-modal/components/ExceptionInfo/ExceptionRecord.js +131 -0
- package/lib/vtx-cc-cp-modal/components/ExceptionInfo/ExceptionRecord.js.map +1 -0
- package/lib/vtx-cc-cp-modal/components/ExceptionInfo/MonthTrend.js +104 -0
- package/lib/vtx-cc-cp-modal/components/ExceptionInfo/MonthTrend.js.map +1 -0
- package/lib/vtx-cc-cp-modal/components/ExceptionInfo/Summary.js +135 -0
- package/lib/vtx-cc-cp-modal/components/ExceptionInfo/Summary.js.map +1 -0
- package/lib/vtx-cc-cp-modal/components/ExceptionInfo/index.css +116 -0
- package/lib/vtx-cc-cp-modal/components/ExceptionInfo/index.js +35 -0
- package/lib/vtx-cc-cp-modal/components/ExceptionInfo/index.js.map +1 -0
- package/lib/vtx-cc-cp-modal/components/ExceptionInfo/index.less +104 -0
- package/lib/vtx-cc-cp-modal/components/Restaurant/index.css +7 -0
- package/lib/vtx-cc-cp-modal/components/Restaurant/index.js +125 -0
- package/lib/vtx-cc-cp-modal/components/Restaurant/index.js.map +1 -0
- package/lib/vtx-cc-cp-modal/components/Restaurant/index.less +7 -0
- package/lib/vtx-cc-cp-modal/components/SyInfo/Ljcsl.js +111 -0
- package/lib/vtx-cc-cp-modal/components/SyInfo/Ljcsl.js.map +1 -0
- package/lib/vtx-cc-cp-modal/components/SyInfo/SummaryInfo.js +118 -0
- package/lib/vtx-cc-cp-modal/components/SyInfo/SummaryInfo.js.map +1 -0
- package/lib/vtx-cc-cp-modal/components/SyInfo/index.css +46 -0
- package/lib/vtx-cc-cp-modal/components/SyInfo/index.js +84 -0
- package/lib/vtx-cc-cp-modal/components/SyInfo/index.js.map +1 -0
- package/lib/vtx-cc-cp-modal/components/SyInfo/index.less +40 -0
- package/lib/vtx-cc-cp-modal/components/index.js +42 -0
- package/lib/vtx-cc-cp-modal/components/index.js.map +1 -0
- package/lib/vtx-cc-cp-modal/index.js +67 -0
- package/lib/vtx-cc-cp-modal/index.js.map +1 -0
- package/lib/vtx-cc-cp-modal/style/css.js +5 -0
- package/lib/vtx-cc-cp-modal/style/css.js.map +1 -0
- package/lib/vtx-cc-cp-modal/style/index.css +84 -0
- package/lib/vtx-cc-cp-modal/style/index.js +5 -0
- package/lib/vtx-cc-cp-modal/style/index.js.map +1 -0
- package/lib/vtx-cc-cp-modal/style/index.less +1 -0
- package/lib/vtx-cc-cp-modal/type.js +6 -0
- package/lib/vtx-cc-cp-modal/type.js.map +1 -0
- package/lib/vtx-restaurant-modal/api.js +35 -36
- package/lib/vtx-restaurant-modal/api.js.map +1 -1
- package/lib/vtx-restaurant-modal/components/Alarm/AlarmRecord.js +4 -4
- package/lib/vtx-restaurant-modal/components/Alarm/AlarmRecord.js.map +1 -1
- package/lib/vtx-restaurant-modal/components/Alarm/AlarmTrend.js +3 -2
- package/lib/vtx-restaurant-modal/components/Alarm/AlarmTrend.js.map +1 -1
- package/lib/vtx-restaurant-modal/components/Alarm/AlarmTypeAnalysis.js +7 -8
- package/lib/vtx-restaurant-modal/components/Alarm/AlarmTypeAnalysis.js.map +1 -1
- package/lib/vtx-restaurant-modal/components/Basic/DetailList.js +21 -13
- package/lib/vtx-restaurant-modal/components/Basic/DetailList.js.map +1 -1
- package/lib/vtx-restaurant-modal/components/Basic/Info.js +5 -5
- package/lib/vtx-restaurant-modal/components/Basic/Info.js.map +1 -1
- package/lib/vtx-restaurant-modal/components/Basic/Summary.js +6 -6
- package/lib/vtx-restaurant-modal/components/Basic/Summary.js.map +1 -1
- package/lib/vtx-restaurant-modal/components/Basic/index.js +2 -2
- package/lib/vtx-restaurant-modal/components/Basic/index.js.map +1 -1
- package/lib/vtx-restaurant-modal/components/Collection/index.js +2 -2
- package/lib/vtx-restaurant-modal/components/Collection/index.js.map +1 -1
- package/lib/vtx-restaurant-modal/config.js +8 -5
- package/lib/vtx-restaurant-modal/config.js.map +1 -1
- package/lib/vtx-restaurant-modal/index.js +4 -4
- package/lib/vtx-restaurant-modal/index.js.map +1 -1
- package/package.json +1 -1
|
@@ -0,0 +1,116 @@
|
|
|
1
|
+
.cc-cp-exception {
|
|
2
|
+
margin: 6px;
|
|
3
|
+
width: 100%;
|
|
4
|
+
}
|
|
5
|
+
.cc-cp-exception .exception-summary {
|
|
6
|
+
padding: 14px 20px;
|
|
7
|
+
background-color: var(--bg-color2);
|
|
8
|
+
}
|
|
9
|
+
.cc-cp-exception .exception-summary-time {
|
|
10
|
+
margin: 24px;
|
|
11
|
+
display: -webkit-box;
|
|
12
|
+
display: -ms-flexbox;
|
|
13
|
+
display: flex;
|
|
14
|
+
-webkit-box-pack: start;
|
|
15
|
+
-ms-flex-pack: start;
|
|
16
|
+
justify-content: start;
|
|
17
|
+
-webkit-box-align: center;
|
|
18
|
+
-ms-flex-align: center;
|
|
19
|
+
align-items: center;
|
|
20
|
+
}
|
|
21
|
+
.cc-cp-exception .exception-summary-time img {
|
|
22
|
+
width: 46px;
|
|
23
|
+
height: 46px;
|
|
24
|
+
margin-right: 19px;
|
|
25
|
+
}
|
|
26
|
+
.cc-cp-exception .exception-summary-time-name {
|
|
27
|
+
font-size: 12px;
|
|
28
|
+
color: var(--title-color);
|
|
29
|
+
}
|
|
30
|
+
.cc-cp-exception .exception-summary-time-value {
|
|
31
|
+
color: var(--title-color);
|
|
32
|
+
font-size: 12px;
|
|
33
|
+
}
|
|
34
|
+
.cc-cp-exception .exception-summary-time-value span {
|
|
35
|
+
font-size: 20px;
|
|
36
|
+
line-height: 25px;
|
|
37
|
+
}
|
|
38
|
+
.cc-cp-exception .exception-summary-time-value-compare {
|
|
39
|
+
display: inline-block;
|
|
40
|
+
margin-left: 36px;
|
|
41
|
+
}
|
|
42
|
+
.cc-cp-exception .exception-summary .triangle-up {
|
|
43
|
+
width: 12px;
|
|
44
|
+
height: 8px;
|
|
45
|
+
position: relative;
|
|
46
|
+
overflow: hidden;
|
|
47
|
+
display: inline-block;
|
|
48
|
+
margin-left: 4px;
|
|
49
|
+
}
|
|
50
|
+
.cc-cp-exception .exception-summary .triangle-up::before {
|
|
51
|
+
content: '';
|
|
52
|
+
position: absolute;
|
|
53
|
+
top: 0;
|
|
54
|
+
left: 0;
|
|
55
|
+
right: 0;
|
|
56
|
+
bottom: 0;
|
|
57
|
+
background: #f65861;
|
|
58
|
+
-webkit-transform-origin: left bottom;
|
|
59
|
+
-ms-transform-origin: left bottom;
|
|
60
|
+
transform-origin: left bottom;
|
|
61
|
+
-webkit-transform: rotate(45deg);
|
|
62
|
+
-ms-transform: rotate(45deg);
|
|
63
|
+
transform: rotate(45deg);
|
|
64
|
+
}
|
|
65
|
+
.cc-cp-exception .exception-summary .triangle-down {
|
|
66
|
+
width: 12px;
|
|
67
|
+
height: 8px;
|
|
68
|
+
position: relative;
|
|
69
|
+
overflow: hidden;
|
|
70
|
+
display: inline-block;
|
|
71
|
+
margin-left: 4px;
|
|
72
|
+
margin-bottom: -2px;
|
|
73
|
+
}
|
|
74
|
+
.cc-cp-exception .exception-summary .triangle-down::before {
|
|
75
|
+
content: '';
|
|
76
|
+
position: absolute;
|
|
77
|
+
top: 0;
|
|
78
|
+
left: 0;
|
|
79
|
+
right: 0;
|
|
80
|
+
bottom: 0;
|
|
81
|
+
background: #41ffb4;
|
|
82
|
+
-webkit-transform-origin: right top;
|
|
83
|
+
-ms-transform-origin: right top;
|
|
84
|
+
transform-origin: right top;
|
|
85
|
+
-webkit-transform: rotate(45deg);
|
|
86
|
+
-ms-transform: rotate(45deg);
|
|
87
|
+
transform: rotate(45deg);
|
|
88
|
+
}
|
|
89
|
+
.cc-cp-exception .exception-trend {
|
|
90
|
+
height: 358px;
|
|
91
|
+
padding: 14px 20px;
|
|
92
|
+
background-color: var(--bg-color2);
|
|
93
|
+
}
|
|
94
|
+
.cc-cp-exception .exception-record {
|
|
95
|
+
padding: 14px 20px;
|
|
96
|
+
background-color: var(--bg-color2);
|
|
97
|
+
min-height: 180px;
|
|
98
|
+
}
|
|
99
|
+
.cc-cp-exception .exception-record-head {
|
|
100
|
+
display: -webkit-box;
|
|
101
|
+
display: -ms-flexbox;
|
|
102
|
+
display: flex;
|
|
103
|
+
-webkit-box-pack: justify;
|
|
104
|
+
-ms-flex-pack: justify;
|
|
105
|
+
justify-content: space-between;
|
|
106
|
+
-webkit-box-align: center;
|
|
107
|
+
-ms-flex-align: center;
|
|
108
|
+
align-items: center;
|
|
109
|
+
}
|
|
110
|
+
.cc-cp-exception .exception-record-table {
|
|
111
|
+
margin-top: 14px;
|
|
112
|
+
height: 200px;
|
|
113
|
+
}
|
|
114
|
+
.cc-cp-exception .exception-record .exceptionLevel img {
|
|
115
|
+
margin-top: -2px;
|
|
116
|
+
}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports["default"] = void 0;
|
|
7
|
+
var _react = _interopRequireDefault(require("react"));
|
|
8
|
+
require("./index.less");
|
|
9
|
+
var _antd = require("antd");
|
|
10
|
+
var _Summary = _interopRequireDefault(require("./Summary"));
|
|
11
|
+
var _MonthTrend = _interopRequireDefault(require("./MonthTrend"));
|
|
12
|
+
var _ExceptionRecord = _interopRequireDefault(require("./ExceptionRecord"));
|
|
13
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
14
|
+
var ExceptionInfo = function ExceptionInfo() {
|
|
15
|
+
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
16
|
+
className: "cc-cp-exception"
|
|
17
|
+
}, /*#__PURE__*/_react["default"].createElement(_antd.Row, {
|
|
18
|
+
gutter: [10, 10]
|
|
19
|
+
}, /*#__PURE__*/_react["default"].createElement(_antd.Col, {
|
|
20
|
+
xxl: 10,
|
|
21
|
+
xl: 11,
|
|
22
|
+
lg: 12,
|
|
23
|
+
md: 24
|
|
24
|
+
}, /*#__PURE__*/_react["default"].createElement(_Summary["default"], null)), /*#__PURE__*/_react["default"].createElement(_antd.Col, {
|
|
25
|
+
xxl: 14,
|
|
26
|
+
xl: 13,
|
|
27
|
+
lg: 12,
|
|
28
|
+
md: 24
|
|
29
|
+
}, /*#__PURE__*/_react["default"].createElement(_MonthTrend["default"], null)), /*#__PURE__*/_react["default"].createElement(_antd.Col, {
|
|
30
|
+
span: 24
|
|
31
|
+
}, /*#__PURE__*/_react["default"].createElement(_ExceptionRecord["default"], null))));
|
|
32
|
+
};
|
|
33
|
+
var _default = ExceptionInfo;
|
|
34
|
+
exports["default"] = _default;
|
|
35
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","names":["_react","_interopRequireDefault","require","_antd","_Summary","_MonthTrend","_ExceptionRecord","obj","__esModule","ExceptionInfo","React","createElement","className","Row","gutter","Col","xxl","xl","lg","md","Summary","MonthTrend","span","ExceptionRecord","_default","exports"],"sources":["vtx-cc-cp-modal/components/ExceptionInfo/index.js"],"sourcesContent":["import React from 'react';\nimport './index.less';\nimport { Col, Row } from 'antd';\nimport Summary from './Summary';\nimport MonthTrend from './MonthTrend';\nimport ExceptionRecord from './ExceptionRecord';\nconst ExceptionInfo = () => {\n return (React.createElement(\"div\", { className: \"cc-cp-exception\" },\n React.createElement(Row, { gutter: [10, 10] },\n React.createElement(Col, { xxl: 10, xl: 11, lg: 12, md: 24 },\n React.createElement(Summary, null)),\n React.createElement(Col, { xxl: 14, xl: 13, lg: 12, md: 24 },\n React.createElement(MonthTrend, null)),\n React.createElement(Col, { span: 24 },\n React.createElement(ExceptionRecord, null)))));\n};\nexport default ExceptionInfo;\n"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,sBAAA,CAAAC,OAAA;AACAA,OAAA;A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6px;
|
|
3
|
+
width: 100%;
|
|
4
|
+
.exception-summary {
|
|
5
|
+
padding: 14px 20px;
|
|
6
|
+
background-color: var(--bg-color2);
|
|
7
|
+
|
|
8
|
+
&-time {
|
|
9
|
+
margin: 24px;
|
|
10
|
+
display: flex;
|
|
11
|
+
justify-content: start;
|
|
12
|
+
align-items: center;
|
|
13
|
+
img {
|
|
14
|
+
width: 46px;
|
|
15
|
+
height: 46px;
|
|
16
|
+
margin-right: 19px;
|
|
17
|
+
}
|
|
18
|
+
&-name {
|
|
19
|
+
font-size: 12px;
|
|
20
|
+
color: var(--title-color);
|
|
21
|
+
}
|
|
22
|
+
&-value {
|
|
23
|
+
color: var(--title-color);
|
|
24
|
+
font-size: 12px;
|
|
25
|
+
span {
|
|
26
|
+
font-size: 20px;
|
|
27
|
+
line-height: 25px;
|
|
28
|
+
}
|
|
29
|
+
&-compare {
|
|
30
|
+
display: inline-block;
|
|
31
|
+
margin-left: 36px;
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
.triangle-up {
|
|
36
|
+
width: 12px;
|
|
37
|
+
height: 8px;
|
|
38
|
+
position: relative;
|
|
39
|
+
overflow: hidden;
|
|
40
|
+
display: inline-block;
|
|
41
|
+
margin-left: 4px;
|
|
42
|
+
&::before {
|
|
43
|
+
content: '';
|
|
44
|
+
position: absolute;
|
|
45
|
+
top: 0;
|
|
46
|
+
left: 0;
|
|
47
|
+
right: 0;
|
|
48
|
+
bottom: 0;
|
|
49
|
+
background: #f65861;
|
|
50
|
+
transform-origin: left bottom;
|
|
51
|
+
transform: rotate(45deg);
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
.triangle-down {
|
|
55
|
+
width: 12px;
|
|
56
|
+
height: 8px;
|
|
57
|
+
position: relative;
|
|
58
|
+
overflow: hidden;
|
|
59
|
+
display: inline-block;
|
|
60
|
+
margin-left: 4px;
|
|
61
|
+
margin-bottom: -2px;
|
|
62
|
+
&::before {
|
|
63
|
+
content: '';
|
|
64
|
+
position: absolute;
|
|
65
|
+
top: 0;
|
|
66
|
+
left: 0;
|
|
67
|
+
right: 0;
|
|
68
|
+
bottom: 0;
|
|
69
|
+
background: #41ffb4;
|
|
70
|
+
transform-origin: right top;
|
|
71
|
+
transform: rotate(45deg);
|
|
72
|
+
}
|
|
73
|
+
}
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
.exception-trend {
|
|
77
|
+
height: 358px;
|
|
78
|
+
padding: 14px 20px;
|
|
79
|
+
background-color: var(--bg-color2);
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
.exception-record {
|
|
83
|
+
padding: 14px 20px;
|
|
84
|
+
background-color: var(--bg-color2);
|
|
85
|
+
min-height: 180px;
|
|
86
|
+
|
|
87
|
+
&-head {
|
|
88
|
+
display: flex;
|
|
89
|
+
justify-content: space-between;
|
|
90
|
+
align-items: center;
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
&-table {
|
|
94
|
+
margin-top: 14px;
|
|
95
|
+
height: 200px;
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
.exceptionLevel {
|
|
99
|
+
img {
|
|
100
|
+
margin-top: -2px;
|
|
101
|
+
}
|
|
102
|
+
}
|
|
103
|
+
}
|
|
104
|
+
}
|
|
@@ -0,0 +1,125 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
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); }
|
|
4
|
+
Object.defineProperty(exports, "__esModule", {
|
|
5
|
+
value: true
|
|
6
|
+
});
|
|
7
|
+
exports["default"] = void 0;
|
|
8
|
+
var _react = _interopRequireWildcard(require("react"));
|
|
9
|
+
require("./index.less");
|
|
10
|
+
var _ahooks = require("ahooks");
|
|
11
|
+
var _api = require("@/vtx-cc-cp-modal/api");
|
|
12
|
+
var _vtxCcCpModal = require("@/vtx-cc-cp-modal");
|
|
13
|
+
var _vmTable = _interopRequireDefault(require("@/vm-table"));
|
|
14
|
+
var _useSettings2 = _interopRequireDefault(require("@/vm-hooks/useSettings"));
|
|
15
|
+
var _vtxRestaurantModal = _interopRequireDefault(require("@/vtx-restaurant-modal"));
|
|
16
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
17
|
+
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
18
|
+
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
19
|
+
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
20
|
+
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."); }
|
|
21
|
+
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); }
|
|
22
|
+
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; }
|
|
23
|
+
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; } }
|
|
24
|
+
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
25
|
+
var Restaurant = function Restaurant() {
|
|
26
|
+
var _useContext = (0, _react.useContext)(_vtxCcCpModal.CcCpContext),
|
|
27
|
+
id = _useContext.id;
|
|
28
|
+
var _useSettings = (0, _useSettings2["default"])(),
|
|
29
|
+
theme = _useSettings.theme;
|
|
30
|
+
var _useSetState = (0, _ahooks.useSetState)({
|
|
31
|
+
pagination: {
|
|
32
|
+
current: 1,
|
|
33
|
+
pageSize: 10,
|
|
34
|
+
total: 0
|
|
35
|
+
}
|
|
36
|
+
}),
|
|
37
|
+
_useSetState2 = _slicedToArray(_useSetState, 2),
|
|
38
|
+
state = _useSetState2[0],
|
|
39
|
+
setState = _useSetState2[1];
|
|
40
|
+
var _useSetState3 = (0, _ahooks.useSetState)({
|
|
41
|
+
title: '',
|
|
42
|
+
visible: false,
|
|
43
|
+
id: ''
|
|
44
|
+
}),
|
|
45
|
+
_useSetState4 = _slicedToArray(_useSetState3, 2),
|
|
46
|
+
modalInfo = _useSetState4[0],
|
|
47
|
+
setModalInfo = _useSetState4[1];
|
|
48
|
+
var pagination = state.pagination;
|
|
49
|
+
var data = _api.BasicService.useRestaurantList({
|
|
50
|
+
id: id,
|
|
51
|
+
page: pagination.current - 1
|
|
52
|
+
});
|
|
53
|
+
var pageChange = function pageChange(page) {
|
|
54
|
+
setState({
|
|
55
|
+
pagination: Object.assign(Object.assign({}, state.pagination), {
|
|
56
|
+
current: page
|
|
57
|
+
})
|
|
58
|
+
});
|
|
59
|
+
};
|
|
60
|
+
var tableProps = {
|
|
61
|
+
rowKey: 'id',
|
|
62
|
+
pagination: Object.assign(Object.assign({}, state.pagination), {
|
|
63
|
+
total: data.total,
|
|
64
|
+
defaultPageSize: 10,
|
|
65
|
+
onChange: pageChange
|
|
66
|
+
}),
|
|
67
|
+
height: 500,
|
|
68
|
+
dataSource: data.rows
|
|
69
|
+
};
|
|
70
|
+
var columns = [{
|
|
71
|
+
title: '商户名称',
|
|
72
|
+
dataIndex: 'name',
|
|
73
|
+
key: 'name',
|
|
74
|
+
// render: (text: string, record: any) => {
|
|
75
|
+
// return (
|
|
76
|
+
// <a onClick={() => setModalInfo({ visible: true, title: text, id: record.id })}>
|
|
77
|
+
// {text}
|
|
78
|
+
// </a>
|
|
79
|
+
// );
|
|
80
|
+
// },
|
|
81
|
+
ellipsis: true
|
|
82
|
+
}, {
|
|
83
|
+
title: '商户编号',
|
|
84
|
+
dataIndex: 'code',
|
|
85
|
+
key: 'code'
|
|
86
|
+
}, {
|
|
87
|
+
title: '行政区划',
|
|
88
|
+
dataIndex: 'divisionName',
|
|
89
|
+
key: 'divisionName'
|
|
90
|
+
}, {
|
|
91
|
+
title: '商户地址',
|
|
92
|
+
dataIndex: 'address',
|
|
93
|
+
key: 'address',
|
|
94
|
+
ellipsis: true
|
|
95
|
+
}, {
|
|
96
|
+
title: '商户类型',
|
|
97
|
+
dataIndex: 'classesName',
|
|
98
|
+
key: 'classesName',
|
|
99
|
+
width: 100
|
|
100
|
+
}, {
|
|
101
|
+
title: '商户规模',
|
|
102
|
+
dataIndex: 'scaleName',
|
|
103
|
+
key: 'scaleName',
|
|
104
|
+
width: 100
|
|
105
|
+
}];
|
|
106
|
+
return /*#__PURE__*/_react["default"].createElement(_react["default"].Fragment, null, /*#__PURE__*/_react["default"].createElement("div", {
|
|
107
|
+
className: "cc-cp-restaurant"
|
|
108
|
+
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
109
|
+
className: "cc-cp-restaurant-table"
|
|
110
|
+
}, /*#__PURE__*/_react["default"].createElement(_vmTable["default"], Object.assign({
|
|
111
|
+
columns: columns
|
|
112
|
+
}, tableProps)))), /*#__PURE__*/_react["default"].createElement(_vtxRestaurantModal["default"], Object.assign({}, modalInfo, {
|
|
113
|
+
theme: theme,
|
|
114
|
+
onCancel: function onCancel() {
|
|
115
|
+
return setModalInfo({
|
|
116
|
+
title: '',
|
|
117
|
+
visible: false,
|
|
118
|
+
id: ''
|
|
119
|
+
});
|
|
120
|
+
}
|
|
121
|
+
})));
|
|
122
|
+
};
|
|
123
|
+
var _default = Restaurant;
|
|
124
|
+
exports["default"] = _default;
|
|
125
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","names":["_react","_interopRequireWildcard","require","_ahooks","_api","_vtxCcCpModal","_vmTable","_interopRequireDefault","_useSettings2","_vtxRestaurantModal","obj","__esModule","_getRequireWildcardCache","nodeInterop","WeakMap","cacheBabelInterop","cacheNodeInterop","_typeof","cache","has","get","newObj","hasPropertyDescriptor","Object","defineProperty","getOwnPropertyDescriptor","key","prototype","hasOwnProperty","call","desc","set","_slicedToArray","arr","i","_arrayWithHoles","_iterableToArrayLimit","_unsupportedIterableToArray","_nonIterableRest","TypeError","o","minLen","_arrayLikeToArray","n","toString","slice","constructor","name","Array","from","test","len","length","arr2","_i","Symbol","iterator","_s","_e","_x","_r","_arr","_n","_d","next","done","push","value","err","isArray","Restaurant","_useContext","useContext","CcCpContext","id","_useSettings","useSettings","theme","_useSetState","useSetState","pagination","current","pageSize","total","_useSetState2","state","setState","_useSetState3","title","visible","_useSetState4","modalInfo","setModalInfo","data","BasicService","useRestaurantList","page","pageChange","assign","tableProps","rowKey","defaultPageSize","onChange","height","dataSource","rows","columns","dataIndex","ellipsis","width","React","createElement","Fragment","className","VMTable","VtxRestaurantModal","onCancel","_default","exports"],"sources":["vtx-cc-cp-modal/components/Restaurant/index.js"],"sourcesContent":["import React, { useContext } from 'react';\nimport './index.less';\nimport { useSetState } from 'ahooks';\nimport { BasicService } from '@/vtx-cc-cp-modal/api';\nimport { CcCpContext } from '@/vtx-cc-cp-modal';\nimport VMTable from '@/vm-table';\nimport useSettings from '@/vm-hooks/useSettings';\nimport VtxRestaurantModal from '@/vtx-restaurant-modal';\nconst Restaurant = () => {\n const { id } = useContext(CcCpContext);\n const { theme } = useSettings();\n const [state, setState] = useSetState({\n pagination: {\n current: 1,\n pageSize: 10,\n total: 0,\n },\n });\n const [modalInfo, setModalInfo] = useSetState({\n title: '',\n visible: false,\n id: '',\n });\n const { pagination } = state;\n const data = BasicService.useRestaurantList({ id, page: pagination.current - 1 });\n const pageChange = (page) => {\n setState({\n pagination: Object.assign(Object.assign({}, state.pagination), { current: page }),\n });\n };\n const tableProps = {\n rowKey: 'id',\n pagination: Object.assign(Object.assign({}, state.pagination), { total: data.total, defaultPageSize: 10, onChange: pageChange }),\n height: 500,\n dataSource: data.rows,\n };\n const columns = [\n {\n title: '商户名称',\n dataIndex: 'name',\n key: 'name',\n // render: (text: string, record: any) => {\n // return (\n // <a onClick={() => setModalInfo({ visible: true, title: text, id: record.id })}>\n // {text}\n // </a>\n // );\n // },\n ellipsis: true,\n },\n {\n title: '商户编号',\n dataIndex: 'code',\n key: 'code',\n },\n {\n title: '行政区划',\n dataIndex: 'divisionName',\n key: 'divisionName',\n },\n {\n title: '商户地址',\n dataIndex: 'address',\n key: 'address',\n ellipsis: true,\n },\n {\n title: '商户类型',\n dataIndex: 'classesName',\n key: 'classesName',\n width: 100\n },\n {\n title: '商户规模',\n dataIndex: 'scaleName',\n key: 'scaleName',\n width: 100\n },\n ];\n return (React.createElement(React.Fragment, null,\n React.createElement(\"div\", { className: \"cc-cp-restaurant\" },\n React.createElement(\"div\", { className: \"cc-cp-restaurant-table\" },\n React.createElement(VMTable, Object.assign({ columns: columns }, tableProps)))),\n React.createElement(VtxRestaurantModal, Object.assign({}, modalInfo, { theme: theme, onCancel: () => setModalInfo({\n title: '',\n visible: false,\n id: '',\n }) }))));\n};\nexport default Restaurant;\n"],"mappings":";;;;;;;AAAA,IAAAA,MAAA,GAAAC,uBAAA,CAAAC,OAAA;AACAA,OAAA;AACA,IAAAC,OAAA,GAAAD,OAAA;AACA,IAAAE,IAAA,GAAAF,OAAA;AACA,IAAAG,aAAA,GAAAH,OAAA;AACA,IAAAI,QAAA,GAAAC,sBAAA,CAAAL,OAAA;AACA,IAAAM,aAAA,GAAAD,sBAAA,CAAAL,OAAA;AACA,IAAAO,mBAAA,GAAAF,sBAAA,CAAAL,OAAA;AAAwD,SAAAK,uBAAAG,GAAA,WAAAA,GAAA,IAAAA,GAAA,CAAAC,UAAA,GAAAD,GAAA,gBAAAA,GAAA;AAAA,SAAAE,yBAAAC,WAAA,eAAAC,OAAA,kCAAAC,iBAAA,OAAAD,OAAA,QAAAE,gBAAA,OAAAF,OAAA,YAAAF,wBAAA,YAAAA,yBAAAC,WAAA,WAAAA,WAAA,GAAAG,gBAAA,GAAAD,iBAAA,KAAAF,WAAA;AAAA,SAAAZ,wBAAAS,GAAA,EAAAG,WAAA,SAAAA,WAAA,IAAAH,GAAA,IAAAA,GAAA,CAAAC,UAAA,WAAAD,GAAA,QAAAA,GAAA,aAAAO,OAAA,CAAAP,GAAA,yBAAAA,GAAA,uCAAAA,GAAA,UAAAQ,KAAA,GAAAN,wBAA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AAEE,SAAS,EAAE;EAAyB,CAAC,eAC9DH,iBAAK,CAACC,aAAa,CAACG,mBAAO,EAAE3F,MAAM,CAAC2E,MAAM,CAAC;IAAEQ,OAAO,EAAEA;EAAQ,CAAC,EAAEP,UAAU,CAAC,CAAC,CAAC,CAAC,eACvFW,iBAAK,CAACC,aAAa,CAACI,8BAAkB,EAAE5F,MAAM,CAAC2E,MAAM,CAAC,CAAC,CAAC,EAAEP,SAAS,EAAE;IAAEd,KAAK,EAAEA,KAAK;IAAEuC,QAAQ,EAAE,SAAAA,SAAA;MAAA,OAAMxB,YAAY,CAAC;QAC1GJ,KAAK,EAAE,EAAE;QACTC,OAAO,EAAE,KAAK;QACdf,EAAE,EAAE;MACR,CAAC,CAAC;IAAA;EAAC,CAAC,CAAC,CAAC,CAAC;AACnB,CAAC;AAAC,IAAA2C,QAAA,GACa/C,UAAU;AAAAgD,OAAA,cAAAD,QAAA"}
|
|
@@ -0,0 +1,111 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
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); }
|
|
4
|
+
Object.defineProperty(exports, "__esModule", {
|
|
5
|
+
value: true
|
|
6
|
+
});
|
|
7
|
+
exports["default"] = void 0;
|
|
8
|
+
var _react = _interopRequireWildcard(require("react"));
|
|
9
|
+
var echarts = _interopRequireWildcard(require("echarts"));
|
|
10
|
+
var _echartsForReact = _interopRequireDefault(require("echarts-for-react"));
|
|
11
|
+
var _useSettings2 = _interopRequireDefault(require("../../../vm-hooks/useSettings"));
|
|
12
|
+
var _vmNodata = _interopRequireDefault(require("../../../vm-nodata"));
|
|
13
|
+
var _vtxCcCpModal = require("@/vtx-cc-cp-modal");
|
|
14
|
+
var _api = require("@/vtx-cc-cp-modal/api");
|
|
15
|
+
var _lodash = _interopRequireDefault(require("lodash"));
|
|
16
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
17
|
+
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
18
|
+
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
19
|
+
var Ljcsl = function Ljcsl(_ref) {
|
|
20
|
+
var startDay = _ref.startDay,
|
|
21
|
+
endDay = _ref.endDay;
|
|
22
|
+
var _useSettings = (0, _useSettings2["default"])(),
|
|
23
|
+
chartFontColor = _useSettings.chartFontColor;
|
|
24
|
+
var _useContext = (0, _react.useContext)(_vtxCcCpModal.CcCpContext),
|
|
25
|
+
id = _useContext.id;
|
|
26
|
+
var data = _api.BasicService.getSyPointCollectLine(id, startDay, endDay);
|
|
27
|
+
var names = _lodash["default"].map(data, 'labelName');
|
|
28
|
+
var values = _lodash["default"].map(data, 'labelValue');
|
|
29
|
+
var option = {
|
|
30
|
+
color: ['#00FFE7'],
|
|
31
|
+
tooltip: {
|
|
32
|
+
trigger: 'axis'
|
|
33
|
+
},
|
|
34
|
+
legend: {
|
|
35
|
+
itemWith: 6,
|
|
36
|
+
itemHeight: 6,
|
|
37
|
+
textStyle: {
|
|
38
|
+
color: chartFontColor,
|
|
39
|
+
fontSize: 12
|
|
40
|
+
},
|
|
41
|
+
data: ['日产生量']
|
|
42
|
+
},
|
|
43
|
+
grid: {
|
|
44
|
+
left: '8%',
|
|
45
|
+
right: '6%',
|
|
46
|
+
top: 28,
|
|
47
|
+
bottom: 20
|
|
48
|
+
},
|
|
49
|
+
xAxis: {
|
|
50
|
+
type: 'category',
|
|
51
|
+
boundaryGap: true,
|
|
52
|
+
axisTick: {
|
|
53
|
+
show: false
|
|
54
|
+
},
|
|
55
|
+
axisLabel: {
|
|
56
|
+
color: chartFontColor
|
|
57
|
+
},
|
|
58
|
+
data: names
|
|
59
|
+
},
|
|
60
|
+
yAxis: {
|
|
61
|
+
type: 'value',
|
|
62
|
+
name: 'kg',
|
|
63
|
+
min: 0,
|
|
64
|
+
nameTextStyle: {
|
|
65
|
+
color: chartFontColor
|
|
66
|
+
},
|
|
67
|
+
splitNumber: 5,
|
|
68
|
+
axisLabel: {
|
|
69
|
+
color: chartFontColor
|
|
70
|
+
},
|
|
71
|
+
splitLine: {
|
|
72
|
+
lineStyle: {
|
|
73
|
+
type: 'dashed',
|
|
74
|
+
color: 'rgba(151,151,151,0.28)'
|
|
75
|
+
}
|
|
76
|
+
}
|
|
77
|
+
},
|
|
78
|
+
series: [{
|
|
79
|
+
name: '垃圾量',
|
|
80
|
+
type: 'line',
|
|
81
|
+
data: (values === null || values === void 0 ? void 0 : values.length) > 0 ? values : [],
|
|
82
|
+
areaStyle: {
|
|
83
|
+
color: new echarts.graphic.LinearGradient(0, 1, 0, 0, [{
|
|
84
|
+
offset: 0,
|
|
85
|
+
color: 'rgba(0, 0, 0, 0.5)'
|
|
86
|
+
}, {
|
|
87
|
+
offset: 1,
|
|
88
|
+
color: '#00FFE7'
|
|
89
|
+
}])
|
|
90
|
+
}
|
|
91
|
+
}]
|
|
92
|
+
};
|
|
93
|
+
return /*#__PURE__*/_react["default"].createElement(_react["default"].Fragment, null, (values === null || values === void 0 ? void 0 : values.length) > 0 ? /*#__PURE__*/_react["default"].createElement(_echartsForReact["default"], {
|
|
94
|
+
option: option,
|
|
95
|
+
notMerge: true,
|
|
96
|
+
lazyUpdate: true,
|
|
97
|
+
style: {
|
|
98
|
+
height: '150px',
|
|
99
|
+
width: '100%'
|
|
100
|
+
}
|
|
101
|
+
}) : /*#__PURE__*/_react["default"].createElement(_vmNodata["default"], {
|
|
102
|
+
style: {
|
|
103
|
+
height: '150px',
|
|
104
|
+
marginLeft: '50%',
|
|
105
|
+
transform: 'translateX(-50%)'
|
|
106
|
+
}
|
|
107
|
+
}));
|
|
108
|
+
};
|
|
109
|
+
var _default = Ljcsl;
|
|
110
|
+
exports["default"] = _default;
|
|
111
|
+
//# sourceMappingURL=Ljcsl.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Ljcsl.js","names":["_react","_interopRequireWildcard","require","echarts","_echartsForReact","_interopRequireDefault","_useSettings2","_vmNodata","_vtxCcCpModal","_api","_lodash","obj","__esModule","_getRequireWildcardCache","nodeInterop","WeakMap","cacheBabelInterop","cacheNodeInterop","_typeof","cache","has","get","newObj","hasPropertyDescriptor","Object","defineProperty","getOwnPropertyDescriptor","key","prototype","hasOwnProperty","call","desc","set","Ljcsl","_ref","startDay","endDay","_useSettings","useSettings","chartFontColor","_useContext","useContext","CcCpContext","id","data","BasicService","getSyPointCollectLine","names","_","map","values","option","color","tooltip","trigger","legend","itemWith","itemHeight","textStyle","fontSize","grid","left","right","top","bottom","xAxis","type","boundaryGap","axisTick","show","axisLabel","yAxis","name","min","nameTextStyle","splitNumber","splitLine","lineStyle","series","length","areaStyle","graphic","LinearGradient","offset","React","createElement","Fragment","ReactEcharts","notMerge","lazyUpdate","style","height","width","NoData","marginLeft","transform","_default","exports"],"sources":["vtx-cc-cp-modal/components/SyInfo/Ljcsl.js"],"sourcesContent":["import React, { useContext } from 'react';\nimport * as echarts from 'echarts';\nimport ReactEcharts from 'echarts-for-react';\nimport useSettings from '../../../vm-hooks/useSettings';\nimport NoData from '../../../vm-nodata';\nimport { CcCpContext } from '@/vtx-cc-cp-modal';\nimport { BasicService } from '@/vtx-cc-cp-modal/api';\nimport _ from 'lodash';\nconst Ljcsl = ({ startDay, endDay }) => {\n const { chartFontColor } = useSettings();\n const { id } = useContext(CcCpContext);\n const data = BasicService.getSyPointCollectLine(id, startDay, endDay);\n const names = _.map(data, 'labelName');\n const values = _.map(data, 'labelValue');\n const option = {\n color: ['#00FFE7'],\n tooltip: {\n trigger: 'axis',\n },\n legend: {\n itemWith: 6,\n itemHeight: 6,\n textStyle: {\n color: chartFontColor,\n fontSize: 12,\n },\n data: ['日产生量'],\n },\n grid: {\n left: '8%',\n right: '6%',\n top: 28,\n bottom: 20,\n },\n xAxis: {\n type: 'category',\n boundaryGap: true,\n axisTick: {\n show: false,\n },\n axisLabel: {\n color: chartFontColor,\n },\n data: names,\n },\n yAxis: {\n type: 'value',\n name: 'kg',\n min: 0,\n nameTextStyle: {\n color: chartFontColor,\n },\n splitNumber: 5,\n axisLabel: {\n color: chartFontColor,\n },\n splitLine: {\n lineStyle: {\n type: 'dashed',\n color: 'rgba(151,151,151,0.28)',\n },\n },\n },\n series: [\n {\n name: '垃圾量',\n type: 'line',\n data: (values === null || values === void 0 ? void 0 : values.length) > 0 ? values : [],\n areaStyle: {\n color: new echarts.graphic.LinearGradient(0, 1, 0, 0, [\n {\n offset: 0,\n color: 'rgba(0, 0, 0, 0.5)',\n },\n {\n offset: 1,\n color: '#00FFE7',\n },\n ]),\n },\n },\n ],\n };\n return (React.createElement(React.Fragment, null, (values === null || values === void 0 ? void 0 : values.length) > 0 ? (React.createElement(ReactEcharts, { option: option, notMerge: true, lazyUpdate: true, style: { height: '150px', width: '100%' } })) : (React.createElement(NoData, { style: { height: '150px', marginLeft: '50%', transform: 'translateX(-50%)' }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