ZaiZai 1 week geleden
bovenliggende
commit
8aa9f3b944
1 gewijzigde bestanden met toevoegingen van 14 en 1 verwijderingen
  1. 14 1
      src/views/project/list/edit-formula.vue

+ 14 - 1
src/views/project/list/edit-formula.vue

@@ -541,10 +541,23 @@ const handleFormulaMenu = (index, path) => {
             console.error(e)
         }
     } else {
-        console.log(index, path)
+        equationSelect(index, path)
     }
 }
 
+//在等式模式下点选计算式
+const equationSelectEle = ref({})
+const equationSelect = (index, path) => {
+    console.log(index, path)
+    const selectEle = equationSelectEle.value
+    const isValidElement = element => element?.type === 'Element' || element?.type === 'ParamData'
+    if (!selectEle || !isValidElement(selectEle)) {
+        window?.$message.warning('请先选中元素')
+        return
+    }
+    console.log(selectEle)
+}
+
 //获取数据
 const resultFormula = ref([])
 const getWbsFormElementData = async () => {