Commit bf85aa0a authored by knight's avatar knight Committed by wux

bug244 【全部客户/潜在客户--新建潜在客户】新建客户成功后,再次打开新增弹窗时,“主营类别”无数据可选

bug243 【全部客户/潜在客户--新建潜在客户】“主营类别”字段应该是非必填
parent cd14f6ec
<template>
<div>
<el-dialog :title="$t('新建潜在客户信息')" :visible.sync="dialogTableVisible">
<el-dialog :title="$t('新建潜在客户信息')" :visible.sync="dialogTableVisible" :close-on-click-modal=false>
<el-form ref="form" :rules="rules" :model="form" label-width="100px" style="padding: 0 20px;">
<el-form-item prop="name" :label="$t('姓名')">
<el-input v-model="form.name" :placeholder="$t('请输入姓名')"></el-input>
......@@ -243,9 +243,6 @@ export default {
this.form.products.push({ typeId: undefined, productIds: [], productList: [] })
this.getProductListFn(0, [undefined])
console.log('this.form.products :')
console.log(this.form.products)
},
computed: {
isChinese() {
......@@ -257,13 +254,13 @@ export default {
rules() {
return {
products: [
{
required: true,
trigger: "blur",
validator: this.productsValidator
}
],
// products: [
// {
// required: true,
// trigger: "blur",
// validator: this.productsValidator
// }
// ],
name: {required: true, message: this.$t('请输入名称'), target: 'blur'},
customerService: {required: true, message: this.$t('请选择客户经理。'), target: ['blur'], type: 'number'},
customerContacts: [{
......
......@@ -1276,6 +1276,12 @@ export default {
// 新增潜在客户
handleAddPotential() {
this.$refs.potentialCustom.dialogTableVisible = true
this.$nextTick((_) => {
// 每次点击弹出窗口都获取商品信息
this.$refs.potentialCustom.form.products = []
this.$refs.potentialCustom.form.products.push({ typeId: undefined, productIds: [], productList: [] })
this.$refs.potentialCustom.getProductListFn(0,[undefined]);
})
},
/** 删除按钮操作 */
handleDelete(row) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment