提交 d6a07118 authored 作者: 王鹏飞's avatar 王鹏飞

chore: 支付管理列表项目和班级可以联动选择

上级 ce1209a6
...@@ -125,21 +125,11 @@ export default { ...@@ -125,21 +125,11 @@ export default {
confirm_status: [], // 确认状态 confirm_status: [], // 确认状态
taxpayer_type: [], // 纳税人类型 taxpayer_type: [], // 纳税人类型
invoice_color_type: [], // 发票开票状态 invoice_color_type: [], // 发票开票状态
classes: [], // 班级名称
project_classes_map: {}, // 项目对应班级名称
}, },
disabledTicketVisible: false, // 发票状态弹框 selectedProjectId: '',
ticketVisible: false, // 开具发票 tableParams: {
codeVisible: false, // 发票二维码
multipleSelection: [],
payDetailList: {}, // 支付详情列表invoice_type
}
},
computed: {
// 列表配置
tableOptions() {
return {
remote: {
httpRequest: getPayList, // 获取订单列表
params: {
project_id: '', project_id: '',
channel_id: '', channel_id: '',
invoice_status: '', invoice_status: '',
...@@ -160,6 +150,20 @@ export default { ...@@ -160,6 +150,20 @@ export default {
class_name: '', class_name: '',
product_name: '', product_name: '',
}, },
disabledTicketVisible: false, // 发票状态弹框
ticketVisible: false, // 开具发票
codeVisible: false, // 发票二维码
multipleSelection: [],
payDetailList: {}, // 支付详情列表invoice_type
}
},
computed: {
// 列表配置
tableOptions() {
return {
remote: {
httpRequest: getPayList, // 获取订单列表
params: this.tableParams,
beforeRequest: this.beforeRequest, beforeRequest: this.beforeRequest,
}, },
filters: [ filters: [
...@@ -238,7 +242,7 @@ export default { ...@@ -238,7 +242,7 @@ export default {
}, },
{ {
type: 'select', type: 'select',
options: this.conditionList.classes, options: this.classOptions,
prop: 'class_name', prop: 'class_name',
placeholder: '班级名称', placeholder: '班级名称',
}, },
...@@ -464,6 +468,14 @@ export default { ...@@ -464,6 +468,14 @@ export default {
], ],
} }
}, },
// 班级筛选列表
classOptions() {
if (!this.selectedProjectId) {
return this.conditionList.classes || []
}
const projectClassesMap = this.conditionList.project_classes_map || {}
return projectClassesMap[this.selectedProjectId] || []
},
}, },
created() { created() {
window.localStorage.getItem('customColumns') window.localStorage.getItem('customColumns')
...@@ -471,6 +483,11 @@ export default { ...@@ -471,6 +483,11 @@ export default {
}, },
methods: { methods: {
beforeRequest(params) { beforeRequest(params) {
const projectId = params.project_id || ''
if (projectId !== this.selectedProjectId) {
this.selectedProjectId = projectId
params.class_name = ''
}
if (params.first_payment_time) { if (params.first_payment_time) {
const [firstTimeFrom, firstTimeTo] = params.first_payment_time const [firstTimeFrom, firstTimeTo] = params.first_payment_time
params.first_payment_time_from = firstTimeFrom params.first_payment_time_from = firstTimeFrom
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论