|
@@ -30,6 +30,10 @@ const props = defineProps({
|
|
type: [String, Number],
|
|
type: [String, Number],
|
|
default: '',
|
|
default: '',
|
|
},
|
|
},
|
|
|
|
+ dataId: {
|
|
|
|
+ type: [String, Number],
|
|
|
|
+ default: '',
|
|
|
|
+ },
|
|
})
|
|
})
|
|
|
|
|
|
//事件
|
|
//事件
|
|
@@ -59,6 +63,12 @@ watch(() => [
|
|
contractPeriodId.value = periodId
|
|
contractPeriodId.value = periodId
|
|
}, { immediate: true })
|
|
}, { immediate: true })
|
|
|
|
|
|
|
|
+//监听数据
|
|
|
|
+const dataIds = ref({})
|
|
|
|
+watch(() => props.dataId, (id) => {
|
|
|
|
+ dataIds.value = id
|
|
|
|
+}, { deep: true })
|
|
|
|
+
|
|
//监听
|
|
//监听
|
|
watch(isShow, (val) => {
|
|
watch(isShow, (val) => {
|
|
if (val) {
|
|
if (val) {
|
|
@@ -82,10 +92,11 @@ const getTableData = async () => {
|
|
tableData.value = []
|
|
tableData.value = []
|
|
tableLoading.value = true
|
|
tableLoading.value = true
|
|
const { data } = await mainApi.addFormList({
|
|
const { data } = await mainApi.addFormList({
|
|
- contractPeriodId: contractPeriodId.value,
|
|
|
|
- contractId: cid.value,
|
|
|
|
- ids: dataId.value,
|
|
|
|
- nodeId: nodeId.value,
|
|
|
|
|
|
+ contractPeriodId: contractPeriodId.value ?? '',
|
|
|
|
+ contractId: cid.value ?? '',
|
|
|
|
+ ids: dataId.value ?? '',
|
|
|
|
+ nodeId: nodeId.value ?? '',
|
|
|
|
+ id: dataIds.value ?? '',
|
|
})
|
|
})
|
|
tableData.value = getArrValue(data)
|
|
tableData.value = getArrValue(data)
|
|
tableLoading.value = false
|
|
tableLoading.value = false
|
|
@@ -106,9 +117,10 @@ const modalSave = async () => {
|
|
}
|
|
}
|
|
const rowIds = arrToId(rows)
|
|
const rowIds = arrToId(rows)
|
|
const { data } = await mainApi.addResolveForm({
|
|
const { data } = await mainApi.addResolveForm({
|
|
- contractPeriodId: contractPeriodId.value,
|
|
|
|
- contractId: cid.value,
|
|
|
|
- nodeId: nodeId.value,
|
|
|
|
|
|
+ contractPeriodId: contractPeriodId.value ?? '',
|
|
|
|
+ contractId: cid.value ?? '',
|
|
|
|
+ nodeId: nodeId.value ?? '',
|
|
|
|
+ id: dataIds.value ?? '',
|
|
ids: rowIds,
|
|
ids: rowIds,
|
|
})
|
|
})
|
|
emit('finish', getArrValue(data))
|
|
emit('finish', getArrValue(data))
|