8
0
Pārlūkot izejas kodu

分配合同段修改

duy 8 mēneši atpakaļ
vecāks
revīzija
f243591701
1 mainītis faili ar 4 papildinājumiem un 3 dzēšanām
  1. 4 3
      src/views/project/detail/wbs.vue

+ 4 - 3
src/views/project/detail/wbs.vue

@@ -162,8 +162,8 @@ const addTreeClick = () => {
     if (rightTreeData.value.length < 1) {
         //直接把左边勾选的树复制到右侧
         let allTree = deepClone(leftTreeData.value)
-        const halfKeys = right.getHalfCheckedKeys()
-        const keys = right.getCheckedKeys().concat(halfKeys)
+        const halfKeys = left.getHalfCheckedKeys()
+        const keys = left.getCheckedKeys().concat(halfKeys)
         getRightTree(allTree, keys)
         rightTreeData.value = allTree
     } else {
@@ -324,13 +324,14 @@ const saveDataApi = async () => {
     submitLoading.value = true
     const ids = await getTreeAllId('right')
     const { pid, cid } = getObjValue(dataInfo.value)
-    const { code } = contractApi.submitWbsTreeInContract({
+    const { code } = await contractApi.submitWbsTreeInContract({
         wbsId: wbsId.value,
         projectId: pid,
         contractId: cid,
         wbsTreeIds: ids,
     })
     submitLoading.value = false
+   
     if (code === 200) {
         window?.$message?.success('保存成功')
     }