|
|
@@ -117,7 +117,12 @@ const changeTabsFn = async (newTabIndex) => {
|
|
|
*/
|
|
|
const changeStoreFn = row => {
|
|
|
storageStore.updateActivedId(row.storageId);
|
|
|
- window.location.href = '/';
|
|
|
+ if (showBackIcon.value) {
|
|
|
+ router.back()
|
|
|
+ }
|
|
|
+ setTimeout(() => {
|
|
|
+ window.location.reload()
|
|
|
+ }, 500)
|
|
|
}
|
|
|
|
|
|
const fetchNoticeData = async () => {
|
|
|
@@ -146,10 +151,12 @@ onMounted(async () => {
|
|
|
// 判断本地存储仓库id是否存在
|
|
|
if (storeList.value && storeList.value.length > 0) {
|
|
|
if (storageStore.activedId) {
|
|
|
- const isExist = storeList.value.find(item => item.storageId == storageStore.activedId);
|
|
|
+ const isExist = storeList.value.some(item => item.storageId == storageStore.activedId);
|
|
|
if (!isExist) {
|
|
|
storageStore.updateActivedId(storeList.value[0].storageId);
|
|
|
}
|
|
|
+ } else {
|
|
|
+ storageStore.updateActivedId(storeList.value[0].storageId);
|
|
|
}
|
|
|
fetchNoticeData();
|
|
|
fetchgetAmityList();
|