applications/task-work-order/src/views/orderView/orderDataManage/supplyAdd/FormDiaLog.vue
@@ -187,7 +187,6 @@ </el-row> </el-form> <template #footer> <el-button color="#F2F3F5" @click="visible = false">{{ dialogReadonly ? '关闭' : '取消' }}</el-button> <el-button class="save-btn" color="#4C34FF" @@ -198,6 +197,8 @@ > 保存 </el-button> <el-button color="#F2F3F5" :loading="submitting" :disabled="submitting" @click="handleApply">申请</el-button> </template> </el-dialog> </template> @@ -226,6 +227,7 @@ responsibleDeptId: '', dataSource: '', demandInfo: '', demandStatus: '0' }) const dictObj = inject('dictObj') @@ -262,6 +264,7 @@ if (!isValid) return submitting.value = true try { formData.value.demandStatus = '0' await gdSupplyDemandSubmitApi(formData.value) ElMessage.success(dialogMode.value === 'add' ? '新增成功' : '更新成功') visible.value = false @@ -271,6 +274,22 @@ } } // 申请提交 async function handleApply() { const isValid = await formRef.value?.validate().catch(() => false) if (!isValid) return submitting.value = true try { formData.value.demandStatus = '1' await gdSupplyDemandSubmitApi(formData.value) ElMessage.success('申请成功') visible.value = false emit('success') } finally { submitting.value = false } } // 加载详情 async function loadDetail() { if (!formData.value.id) return applications/task-work-order/src/views/orderView/orderDataManage/supplyAdd/index.vue
@@ -54,9 +54,9 @@ <el-table-column prop="contactPhone" show-overflow-tooltip label="需求联系人电话" /> <el-table-column prop="contactEmail" show-overflow-tooltip label="需求邮箱" /> <el-table-column prop="demandStatus" show-overflow-tooltip label="需求状态"> <!-- <template v-slot="{ row }"> <template v-slot="{ row }"> {{ getDictLabel(row.demandStatus, dictObj.demandStatus) }} </template> --> </template> </el-table-column> <el-table-column prop="updateCycle" show-overflow-tooltip label="更新周期" /> <el-table-column prop="applyBasis" show-overflow-tooltip label="申请依据" /> @@ -196,7 +196,7 @@ // 获取字典 function getDictList() { getDictionaryByCode('requirementType,sharedType,appSceneType').then(res => { getDictionaryByCode('requirementType,sharedType,appSceneType,demandStatus').then(res => { dictObj.value = res.data.data }) }