Browse Source

切换项目更新

ZaiZai 4 months ago
parent
commit
a08d1474b2
1 changed files with 2 additions and 2 deletions
  1. 2 2
      src/store/modules/app.js

+ 2 - 2
src/store/modules/app.js

@@ -46,9 +46,9 @@ const getStoreProjecInfo = async (arr) => {
     const projectId = store.projectId //项目ID
     const contractId = store.contractId //合同段ID
     //查询缓存的选中ID是否存在
-    const pid = arr.findIndex(item => Number(item.id) === Number(projectId))
+    const pid = arr.findIndex(item => String(item.id) === String(projectId))
     const contractList = getArrValue(arr[pid]?.contractInfoList)
-    const cid = contractList.findIndex(item => Number(item.id) === Number(contractId))
+    const cid = contractList.findIndex(item => String(item.id) === String(contractId))
     //如果缓存的选中ID不存在
     if (cid === -1) {
         return false