@optifye/dashboard-core 6.10.22 → 6.10.24
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/dist/index.js +5 -11
- package/dist/index.mjs +5 -11
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -49152,17 +49152,11 @@ function HomeView({
|
|
|
49152
49152
|
}
|
|
49153
49153
|
return allLineIds;
|
|
49154
49154
|
}, [isOwner, isPlantHead, isSupervisor, allLineIds, plantHeadLineIds, assignedLineIdsInConfig]);
|
|
49155
|
-
const
|
|
49156
|
-
const
|
|
49157
|
-
const canShowFactoryView = isOwner;
|
|
49158
|
-
const fallbackLineId = visibleLineIds[0] || defaultLineId || factoryViewId;
|
|
49159
|
-
const defaultHomeLineId = shouldDefaultToAllLines && canShowFactoryView ? factoryViewId : fallbackLineId;
|
|
49155
|
+
const fallbackLineId = visibleLineIds[0] || defaultLineId;
|
|
49156
|
+
const defaultHomeLineId = fallbackLineId;
|
|
49160
49157
|
const availableLineIds = React25.useMemo(() => {
|
|
49161
|
-
|
|
49162
|
-
|
|
49163
|
-
}
|
|
49164
|
-
return shouldDefaultToAllLines ? [factoryViewId, ...visibleLineIds] : [...visibleLineIds, factoryViewId];
|
|
49165
|
-
}, [factoryViewId, visibleLineIds, canShowFactoryView, shouldDefaultToAllLines]);
|
|
49158
|
+
return visibleLineIds;
|
|
49159
|
+
}, [visibleLineIds]);
|
|
49166
49160
|
const LINE_FILTER_STORAGE_KEY = "optifye_home_line_filter";
|
|
49167
49161
|
const [selectedLineId, setSelectedLineId] = React25.useState(() => {
|
|
49168
49162
|
if (typeof window === "undefined") {
|
|
@@ -49171,7 +49165,7 @@ function HomeView({
|
|
|
49171
49165
|
try {
|
|
49172
49166
|
const savedLineId = sessionStorage.getItem(LINE_FILTER_STORAGE_KEY);
|
|
49173
49167
|
if (savedLineId) {
|
|
49174
|
-
if (availableLineIds.includes(savedLineId)) {
|
|
49168
|
+
if (savedLineId !== factoryViewId && availableLineIds.includes(savedLineId)) {
|
|
49175
49169
|
return savedLineId;
|
|
49176
49170
|
}
|
|
49177
49171
|
}
|
package/dist/index.mjs
CHANGED
|
@@ -49123,17 +49123,11 @@ function HomeView({
|
|
|
49123
49123
|
}
|
|
49124
49124
|
return allLineIds;
|
|
49125
49125
|
}, [isOwner, isPlantHead, isSupervisor, allLineIds, plantHeadLineIds, assignedLineIdsInConfig]);
|
|
49126
|
-
const
|
|
49127
|
-
const
|
|
49128
|
-
const canShowFactoryView = isOwner;
|
|
49129
|
-
const fallbackLineId = visibleLineIds[0] || defaultLineId || factoryViewId;
|
|
49130
|
-
const defaultHomeLineId = shouldDefaultToAllLines && canShowFactoryView ? factoryViewId : fallbackLineId;
|
|
49126
|
+
const fallbackLineId = visibleLineIds[0] || defaultLineId;
|
|
49127
|
+
const defaultHomeLineId = fallbackLineId;
|
|
49131
49128
|
const availableLineIds = useMemo(() => {
|
|
49132
|
-
|
|
49133
|
-
|
|
49134
|
-
}
|
|
49135
|
-
return shouldDefaultToAllLines ? [factoryViewId, ...visibleLineIds] : [...visibleLineIds, factoryViewId];
|
|
49136
|
-
}, [factoryViewId, visibleLineIds, canShowFactoryView, shouldDefaultToAllLines]);
|
|
49129
|
+
return visibleLineIds;
|
|
49130
|
+
}, [visibleLineIds]);
|
|
49137
49131
|
const LINE_FILTER_STORAGE_KEY = "optifye_home_line_filter";
|
|
49138
49132
|
const [selectedLineId, setSelectedLineId] = useState(() => {
|
|
49139
49133
|
if (typeof window === "undefined") {
|
|
@@ -49142,7 +49136,7 @@ function HomeView({
|
|
|
49142
49136
|
try {
|
|
49143
49137
|
const savedLineId = sessionStorage.getItem(LINE_FILTER_STORAGE_KEY);
|
|
49144
49138
|
if (savedLineId) {
|
|
49145
|
-
if (availableLineIds.includes(savedLineId)) {
|
|
49139
|
+
if (savedLineId !== factoryViewId && availableLineIds.includes(savedLineId)) {
|
|
49146
49140
|
return savedLineId;
|
|
49147
49141
|
}
|
|
49148
49142
|
}
|