Ver código fonte

试验仅保存本表修改

duy 1 mês atrás
pai
commit
ab9e3f4159

+ 7 - 4
src/views/tentative/detect/components/ListItem.vue

@@ -775,6 +775,8 @@ const uploadChartImgFile = async (base64) => {
 const newaddId = ref('')
 //保存表单数据
 const saveExcelBussData = async (item, index, showTip = true) => {
+
+       const { id } = baseData.value
     let saveItem = {}
     formData.value.forEach((ele)=>{
         if (ele.pkeyId === item.pKeyId) {
@@ -793,11 +795,12 @@ const saveExcelBussData = async (item, index, showTip = true) => {
             InitObj[name] = url
         }
         baseData.value.tableType = tabTypeKeyInfo.value
-        if (newaddId.value.length > 0) {
-            baseData.value.id = newaddId.value
-        }
-
+        // if (newaddId.value.length > 0) {
+        //     baseData.value.id = newaddId.value
+        // }
+     baseData.value.id = id || nodeIdvaluedata.value || newaddId.value
         const { error, code, data, msg } = await dataApi.saveExcelBussData({
+             
             ...baseData.value,
             isBatchSave: 0,
             dataInfo: {

+ 1 - 1
src/views/tentative/detect/components/basicInfo.vue

@@ -384,7 +384,7 @@ infoLoad.value = true
     //处理数据
 infoLoad.value = false
     if (!error && code === 200) {
-      console.log(data, '基础信息数据')
+    
         basicInfoData.value = getObjValue(data)
         standardId.value = data?.standardId