diff --git a/src/api/crm/quotation/index.ts b/src/api/crm/quotation/index.ts
index 4fe63d92c..1c7f77da4 100644
--- a/src/api/crm/quotation/index.ts
+++ b/src/api/crm/quotation/index.ts
@@ -65,6 +65,11 @@ export const QuotationApi = {
return await request.download({ url: `/crm/quotation/export-excel`, params })
},
+ // 提交审核
+ submitContract: async (id: number) => {
+ return await request.put({ url: `/crm/quotation/submit?id=${id}` })
+ },
+
// ==================== 子表(CRM 报价产品关联) ====================
// 获得CRM 报价产品关联列表
diff --git a/src/views/crm/quotation/QuotationForm.vue b/src/views/crm/quotation/QuotationForm.vue
index 47ad8d732..afa59c37e 100644
--- a/src/views/crm/quotation/QuotationForm.vue
+++ b/src/views/crm/quotation/QuotationForm.vue
@@ -538,6 +538,7 @@ const onCustomerChange = async (customerId: string) => {
formData.value.dishonestRecord = customerRes.dishonestRecord;
formData.value.financingRecord = customerRes.financingRecord;
formData.value.enforcementRecord = customerRes.enforcementRecord;
+ formData.value.creditAmount = customerRes.creditAmount || 0;
} catch (err) {
console.error('获取客户详情失败:', err);
} finally {
@@ -661,7 +662,7 @@ onMounted(async () => {
if (formType.value) open(formType.value)
// 获得客户列表
- customerList.value = await CustomerApi.getCustomerSimpleList()
+ customerList.value = await CustomerApi.getSelfCustomerSimpleList()
// 获得用户列表
userOptions.value = await UserApi.getSimpleUserList()
//票据
diff --git a/src/views/crm/quotation/index.vue b/src/views/crm/quotation/index.vue
index a94f5f756..13e9f1e34 100644
--- a/src/views/crm/quotation/index.vue
+++ b/src/views/crm/quotation/index.vue
@@ -177,6 +177,12 @@
更多
+
+ 提交审核
+
{
/** 操作分发 */
const handleCommand = (command: string, row: UserApi.UserVO) => {
switch (command) {
+ case 'handleSubmit':
+ handleSubmit(row)
+ break
case 'handleDelete':
handleDelete(row.id)
break
@@ -308,6 +317,14 @@ const handleCommand = (command: string, row: UserApi.UserVO) => {
}
}
+/** 提交审核 **/
+const handleSubmit = async (row: QuotationVO) => {
+ await message.confirm(`您确定提交【${row.name}】审核吗?`)
+ await QuotationApi.submitContract(row.id)
+ message.success('提交审核成功!')
+ await getList()
+}
+
/** 删除按钮操作 */
const handleDelete = async (id: number) => {
try {