|
|
|
@ -151,6 +151,30 @@ |
|
|
|
|
|
|
|
<el-dialog :title="currentRow ? `为发票号 ${currentRow.cmcInvoice} 选择客户模板` : '客户模板'" |
|
|
|
@close="templateFlag = false; currentRow = null" :visible.sync="templateFlag" width="1200px" v-drag> |
|
|
|
<!-- 搜索表单 --> |
|
|
|
<el-form :inline="true" :model="templateSearchData" label-width="100px" style="margin-bottom: 15px;"> |
|
|
|
<el-form-item label="模板名称:"> |
|
|
|
<el-input |
|
|
|
v-model="templateSearchData.templateName" |
|
|
|
placeholder="请输入模板名称" |
|
|
|
style="width: 200px;" |
|
|
|
clearable> |
|
|
|
</el-input> |
|
|
|
</el-form-item> |
|
|
|
<el-form-item label="客户名称:"> |
|
|
|
<el-input |
|
|
|
v-model="templateSearchData.customerName" |
|
|
|
placeholder="请输入客户名称" |
|
|
|
style="width: 200px;" |
|
|
|
clearable> |
|
|
|
</el-input> |
|
|
|
</el-form-item> |
|
|
|
<el-form-item> |
|
|
|
<el-button type="primary" @click="searchTemplateList">查询</el-button> |
|
|
|
<el-button @click="resetTemplateSearch">重置</el-button> |
|
|
|
</el-form-item> |
|
|
|
</el-form> |
|
|
|
|
|
|
|
<el-table |
|
|
|
:height="400" |
|
|
|
:data="customerTemplateList" |
|
|
|
@ -391,6 +415,10 @@ |
|
|
|
overseasAddressFlag:false, |
|
|
|
templateFlag:false, |
|
|
|
customerTemplateList: [],//客户模板列表 |
|
|
|
templateSearchData: { |
|
|
|
templateName: '', |
|
|
|
customerName: '' |
|
|
|
},//模板搜索条件 |
|
|
|
cacheKey: '', // 缓存键 |
|
|
|
cacheTimer: null, // 缓存定时器 |
|
|
|
currentRow: null, // 当前编辑的行 |
|
|
|
@ -1105,9 +1133,9 @@ |
|
|
|
}, |
|
|
|
|
|
|
|
// 获取客户模板列表 |
|
|
|
async getCustomerTemplateList() { |
|
|
|
async getCustomerTemplateList(searchParams = {}) { |
|
|
|
try { |
|
|
|
const { data } = await getCustomerTemplateList({}) |
|
|
|
const { data } = await getCustomerTemplateList(searchParams) |
|
|
|
if (data && data.code === 0) { |
|
|
|
this.customerTemplateList = data.rows || [] |
|
|
|
} |
|
|
|
@ -1117,6 +1145,24 @@ |
|
|
|
} |
|
|
|
}, |
|
|
|
|
|
|
|
// 搜索客户模板 |
|
|
|
searchTemplateList() { |
|
|
|
const searchParams = { |
|
|
|
templateName: this.templateSearchData.templateName, |
|
|
|
customerName: this.templateSearchData.customerName |
|
|
|
} |
|
|
|
this.getCustomerTemplateList(searchParams) |
|
|
|
}, |
|
|
|
|
|
|
|
// 重置模板搜索 |
|
|
|
resetTemplateSearch() { |
|
|
|
this.templateSearchData = { |
|
|
|
templateName: '', |
|
|
|
customerName: '' |
|
|
|
} |
|
|
|
this.getCustomerTemplateList() |
|
|
|
}, |
|
|
|
|
|
|
|
// 获取特定客户的地址信息 |
|
|
|
getCusPersonsForRow(customerName) { |
|
|
|
let cusData = {ccusname: customerName} |
|
|
|
|