pull/781/head
parent
d97996dde6
commit
c9baa7160e
|
|
@ -56,6 +56,7 @@
|
|||
<el-select
|
||||
v-model="formData.maintainer"
|
||||
clearable
|
||||
filterable
|
||||
:disabled="type"
|
||||
placeholder="请选择线维护人"
|
||||
class="w-1/1"
|
||||
|
|
@ -74,7 +75,7 @@
|
|||
<el-select
|
||||
v-model="formData.requestorUserId"
|
||||
clearable
|
||||
|
||||
filterable
|
||||
:disabled="formType || type"
|
||||
:placeholder="formType ? '' : '请选择需求提交人'"
|
||||
class="w-1/1"
|
||||
|
|
@ -203,7 +204,7 @@
|
|||
</el-col>
|
||||
<el-col :span="8">
|
||||
<el-form-item label="平台" prop="platformId">
|
||||
<el-select v-model="formData.platformId" :disabled="type" clearable placeholder="请选择平台">
|
||||
<el-select v-model="formData.platformId" filterable :disabled="type" clearable placeholder="请选择平台">
|
||||
<el-option
|
||||
v-for="dict in techOptions"
|
||||
:key="dict.id"
|
||||
|
|
@ -215,7 +216,7 @@
|
|||
</el-col>
|
||||
<el-col :span="8">
|
||||
<el-form-item label="项目难度" prop="projectDifficultyId">
|
||||
<el-select v-model="formData.projectDifficultyId" :disabled="type" clearable placeholder="请选择项目难度" @change="changeDifficult">
|
||||
<el-select v-model="formData.projectDifficultyId" filterable :disabled="type" clearable placeholder="请选择项目难度" @change="changeDifficult">
|
||||
<el-option
|
||||
v-for="dict in difficultOptions"
|
||||
:key="dict.id"
|
||||
|
|
|
|||
|
|
@ -761,6 +761,7 @@ const open = async (type: string) => {
|
|||
// formLoading.value = true
|
||||
try {
|
||||
formData.value = await ContractApi.getContract(type)
|
||||
// handleQuotationChange(formData.value.quotationId)
|
||||
} finally {
|
||||
formLoading.value = false
|
||||
}
|
||||
|
|
@ -882,6 +883,7 @@ const resetForm = () => {
|
|||
const handleQuotationChange = async (quotationId: number) => {
|
||||
if (!quotationId) return
|
||||
try {
|
||||
console.log('%csrc/views/crm/contract/ContractForm.vue:886 222', 'color: #007acc;', 222);
|
||||
const quotation = await QuotationApi.getQuotation(quotationId)
|
||||
formData.value.products = quotation.products;
|
||||
// formData.value.customerId = quotation.customerId;
|
||||
|
|
@ -928,12 +930,15 @@ const onCustomerChange = async (customerId: string) => {
|
|||
|
||||
try {
|
||||
formLoading.value = true;
|
||||
|
||||
// let customerRes = {}
|
||||
// if(formType.value) {
|
||||
// customerRes = await CustomerApi.getCustomer(customerId);
|
||||
// }else {
|
||||
let customerRes = await CustomerApi.getCustomerDetail(customerId);
|
||||
formData.value.quotationId = customerRes.quotationId;
|
||||
formData.value.servicor = customerRes.servicor;
|
||||
formData.value.technicalLead = customerRes.technicalLead;
|
||||
formData.value.settlementLead = customerRes.settlementLead;
|
||||
// }
|
||||
formData.value.companyType = customerRes.companyType;
|
||||
formData.value.listingStatus = customerRes.listingStatus;
|
||||
|
|
@ -954,9 +959,7 @@ const onCustomerChange = async (customerId: string) => {
|
|||
formData.value.registeredAddress = customerRes.registeredAddress;
|
||||
formData.value.afterSaleUserId = customerRes.maintainer;
|
||||
formData.value.clueDeveloper = customerRes.clueDeveloper;
|
||||
formData.value.servicor = customerRes.servicor;
|
||||
formData.value.technicalLead = customerRes.technicalLead;
|
||||
formData.value.settlementLead = customerRes.settlementLead;
|
||||
|
||||
await handleQuotationChange(customerRes.quotationId);
|
||||
|
||||
} catch (err) {
|
||||
|
|
|
|||
Loading…
Reference in New Issue