easy3wui 1.4.208 → 1.4.212
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/Easy3wFlow/index.js +13 -2
- package/package.json +1 -1
package/lib/Easy3wFlow/index.js
CHANGED
|
@@ -127,13 +127,24 @@ var Easy3wFlow = function (_Component) {
|
|
|
127
127
|
flowCurCode = _this$props.flowCurCode,
|
|
128
128
|
picTrianglePath = _this$props.picTrianglePath,
|
|
129
129
|
flowCurMainCode = _this$props.flowCurMainCode;
|
|
130
|
+
// 初始化选中节点
|
|
130
131
|
|
|
132
|
+
var initMainCode = '';
|
|
133
|
+
if (flowLength > 0) {
|
|
134
|
+
initMainCode = flowCurMainCode || flowData[0].code;
|
|
135
|
+
var findObj = flowData.find(function (item) {
|
|
136
|
+
return item.status === '10';
|
|
137
|
+
});
|
|
138
|
+
if (findObj) {
|
|
139
|
+
initMainCode = flowCurMainCode || findObj.code;
|
|
140
|
+
}
|
|
141
|
+
}
|
|
131
142
|
var renderTopTemp = flowData.map(function (flow, index) {
|
|
132
143
|
var styleflowcircle = (0, _classnames2['default'])(['flowcircle', 'haiergrey']);
|
|
133
144
|
if (flow.status === '10') {
|
|
134
|
-
styleflowcircle =
|
|
145
|
+
styleflowcircle = initMainCode === flow.code ? (0, _classnames2['default'])(['flowcircle-active-haierorange', 'haierorange']) : (0, _classnames2['default'])(['flowcircle', 'haierorange']);
|
|
135
146
|
} else if (flow.status === '20' || flow.status === '30') {
|
|
136
|
-
styleflowcircle =
|
|
147
|
+
styleflowcircle = initMainCode === flow.code ? (0, _classnames2['default'])(['flowcircle-active-haierblue', 'haierblue']) : (0, _classnames2['default'])(['flowcircle', 'haierblue']);
|
|
137
148
|
}
|
|
138
149
|
return _react2['default'].createElement(
|
|
139
150
|
'div',
|