ZaiZai 1 week ago
parent
commit
8aa9f3b944
1 changed files with 14 additions and 1 deletions
  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 () => {