|
@@ -173,6 +173,7 @@ const dictDataStore = DictDataStore()
|
|
const tagsStore = TagsStore()
|
|
const tagsStore = TagsStore()
|
|
const sectorStore = SectorStore()
|
|
const sectorStore = SectorStore()
|
|
const processStore = ProcessStore()
|
|
const processStore = ProcessStore()
|
|
|
|
+const match_id = ref('')
|
|
const data = ref([])
|
|
const data = ref([])
|
|
const searchForm = ref({})
|
|
const searchForm = ref({})
|
|
const fields = [
|
|
const fields = [
|
|
@@ -398,9 +399,10 @@ const toSave = async () => {
|
|
if (get(data, 'id')) res = await store.update({ ...data, ...other })
|
|
if (get(data, 'id')) res = await store.update({ ...data, ...other })
|
|
else res = await store.create({ ...data, ...other })
|
|
else res = await store.create({ ...data, ...other })
|
|
if ($checkRes(res, true)) {
|
|
if ($checkRes(res, true)) {
|
|
- toProcessSave()
|
|
|
|
- search({ skip, limit })
|
|
|
|
- toClose()
|
|
|
|
|
|
+ if (res.data.id) match_id.value = res.data.id
|
|
|
|
+ await toProcessSave()
|
|
|
|
+ await search({ skip, limit })
|
|
|
|
+ await toClose()
|
|
}
|
|
}
|
|
}
|
|
}
|
|
// 审核
|
|
// 审核
|
|
@@ -437,6 +439,7 @@ const toProcessSave = async () => {
|
|
for (const val of processList.value) {
|
|
for (const val of processList.value) {
|
|
const data = cloneDeep(val)
|
|
const data = cloneDeep(val)
|
|
delete data.sid
|
|
delete data.sid
|
|
|
|
+ if (!val.match) val.match = match_id.value
|
|
if (get(data, 'id')) await processStore.update(data)
|
|
if (get(data, 'id')) await processStore.update(data)
|
|
else await processStore.create(data)
|
|
else await processStore.create(data)
|
|
}
|
|
}
|