Эх сурвалжийг харах

关联委托单编号修改

duy 2 сар өмнө
parent
commit
1f84ff6dab

+ 3 - 2
src/views/tentative/detect/components/basicInfo.vue

@@ -508,9 +508,10 @@ const linkCommission = ()=>{
 const isLinksAssociation = ref(false)
 
 //委托单确定选择
-const commissionChange = (id, data) => {
+const commissionChange = (id, data, entrustNo) => {
+console.log(id, data)
 
-    basicInfoData.value.entrustNo = data.specificationNumber
+    basicInfoData.value.entrustNo = entrustNo
      basicInfoData.value.entrustId = id
 
    

+ 8 - 2
src/views/tentative/detect/components/linkAssociation.vue

@@ -182,10 +182,13 @@ const getTableData = async () => {
 
 //选择
 const currentId = ref(null)
-const rowSelect = async ({ id }) => {
+const entrustNoVal = ref('')
+const rowSelect = async ({ id, entrustNo }) => {
     isCountShow.value = true
      formModel.value = {}
     currentId.value = id
+    entrustNoVal.value = entrustNo
+
     const { data } = await mainApi.detail(id)
     formModel.value = getObjValue(data)
         isSelected.value = true // 设置选中状态
@@ -194,6 +197,7 @@ const rowSelect = async ({ id }) => {
 //取消选择
 const rowCancel = () => {
     currentId.value = null
+         entrustNoVal.value = ''
     formModel.value = {}
         isSelected.value = false // 清除选中状态
 }
@@ -202,7 +206,7 @@ const isSelected = ref(false) // 新增状态变量
 const linkSamplingClick = () => {
  
     
-    emit('change', curId.value, formModel.value)
+    emit('change', curId.value, formModel.value, entrustNoVal.value)
     linkSamplingClose()
 }
 
@@ -210,6 +214,8 @@ const linkSamplingClick = () => {
 const linkSamplingClose = () => {
     isShow.value = false
     formModel.value = {}
+     entrustNoVal.value = ''
+
     emit('close')
 }