@vtx/modals2 6.0.0-beta.17 → 6.0.0-beta.18
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.
|
@@ -25,7 +25,8 @@ import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-run
|
|
|
25
25
|
var Charts = function Charts(_ref) {
|
|
26
26
|
var code = _ref.code,
|
|
27
27
|
deviceId = _ref.deviceId,
|
|
28
|
-
handleAbility = _ref.handleAbility
|
|
28
|
+
handleAbility = _ref.handleAbility,
|
|
29
|
+
hasWorkCondition = _ref.hasWorkCondition;
|
|
29
30
|
var _useSettings = useSettings(),
|
|
30
31
|
isDark = _useSettings.isDark;
|
|
31
32
|
var _useSetState = useSetState({
|
|
@@ -112,20 +113,26 @@ var Charts = function Charts(_ref) {
|
|
|
112
113
|
children: [/*#__PURE__*/_jsx("div", {
|
|
113
114
|
className: "df-calendar-head",
|
|
114
115
|
children: [{
|
|
116
|
+
visible: true,
|
|
115
117
|
name: translateLocaleText("t('vtxdfmodal.tons')"),
|
|
116
118
|
img: jcl,
|
|
117
119
|
type: 'blue'
|
|
118
120
|
}, {
|
|
121
|
+
visible: true,
|
|
119
122
|
name: translateLocaleText("t('vtxjzljdftpdmodal.times')"),
|
|
120
123
|
img: car,
|
|
121
124
|
type: 'green'
|
|
122
125
|
}, {
|
|
126
|
+
visible: hasWorkCondition,
|
|
123
127
|
name: translateLocaleText("t('vtxdfmodal.workConditionNormal')"),
|
|
124
128
|
imgType: 'normal'
|
|
125
129
|
}, {
|
|
130
|
+
visible: hasWorkCondition,
|
|
126
131
|
name: translateLocaleText("t('vtxdfmodal.workConditionAbnormal')"),
|
|
127
132
|
imgType: 'alarm'
|
|
128
|
-
}].
|
|
133
|
+
}].filter(function (ele) {
|
|
134
|
+
return ele.visible;
|
|
135
|
+
}).map(function (item, index) {
|
|
129
136
|
return /*#__PURE__*/_jsx(VmCalendarInner, _objectSpread(_objectSpread({}, item), {}, {
|
|
130
137
|
value: item.name
|
|
131
138
|
}), index);
|