✨ 客户列表增加账单入口和权限
This commit is contained in:
@@ -14,7 +14,7 @@
|
||||
<el-button
|
||||
icon="Document"
|
||||
@click="openBillDialog"
|
||||
v-hasPermi="['customersupplier:customerinfo:list']"
|
||||
v-hasPermi="['customersupplier:customerinfo:bill']"
|
||||
>查看账单</el-button>
|
||||
<el-button
|
||||
type="primary"
|
||||
|
||||
@@ -200,11 +200,12 @@
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column v-if="isColVisible('remark')" label="备注说明" align="center" prop="remark" :show-overflow-tooltip="true" />
|
||||
<el-table-column label="操作" align="center" class-name="small-padding fixed-width" width="290" fixed="right">
|
||||
<el-table-column label="操作" align="center" class-name="small-padding fixed-width" width="370" fixed="right">
|
||||
<template #default="scope">
|
||||
<el-button link type="primary" icon="Edit" @click="handleUpdate(scope.row)" v-hasPermi="['customersupplier:customerinfo:edit']">修改</el-button>
|
||||
<!-- <el-button link type="primary" icon="Delete" @click="handleDelete(scope.row)" v-hasPermi="['customersupplier:customerinfo:remove']">删除</el-button>-->
|
||||
<el-button link type="primary" icon="Wallet" @click="handleCustomerMoney(scope.row)" v-hasPermi="['customersupplier:customerinfo:balance']">客户余额</el-button>
|
||||
<el-button link type="primary" icon="Document" @click="handleViewBills(scope.row)" v-hasPermi="['customersupplier:customerinfo:bill']">账单</el-button>
|
||||
<el-button link type="primary" icon="Document" @click="handleViewLog(scope.row)" v-hasPermi="['customersupplier:customerinfo:query']">日志</el-button>
|
||||
</template>
|
||||
|
||||
@@ -293,6 +294,14 @@
|
||||
:customer-code="logCustomer.customerCode"
|
||||
/>
|
||||
|
||||
<customer-bill-list-dialog
|
||||
v-if="billDialogVisible"
|
||||
:key="billCustomer.customerId"
|
||||
v-model="billDialogVisible"
|
||||
:customer-id="billCustomer.customerId"
|
||||
:customer-name="billCustomer.customerName"
|
||||
/>
|
||||
|
||||
<!-- 右键复制列值 -->
|
||||
<table-copy-menu
|
||||
ref="copyMenuRef"
|
||||
@@ -309,6 +318,7 @@ import { listPriceSetOption, batchBindCustomerPriceSet } from "@/api/customersup
|
||||
import { useProducts, parseProductCodes } from '@/components/ProductSelect/useProducts'
|
||||
import { useUsers } from '@/components/UserSelect/useUsers'
|
||||
import CustomerLogDialog from './components/CustomerLogDialog.vue'
|
||||
import CustomerBillListDialog from './customermoney/CustomerBillListDialog.vue'
|
||||
import { useColumnSettings } from '@/utils/columnSettings'
|
||||
|
||||
const { proxy } = getCurrentInstance()
|
||||
@@ -518,6 +528,21 @@ function handleCustomerMoney(row) {
|
||||
})
|
||||
}
|
||||
|
||||
/** 在客户信息列表内打开只读账单弹窗 */
|
||||
const billDialogVisible = ref(false)
|
||||
const billCustomer = ref({})
|
||||
function handleViewBills(row) {
|
||||
if (!row || !row.customerId) {
|
||||
proxy.$modal.msgWarning('客户信息无效,无法查看账单')
|
||||
return
|
||||
}
|
||||
billCustomer.value = {
|
||||
customerId: row.customerId,
|
||||
customerName: row.customerName || ''
|
||||
}
|
||||
billDialogVisible.value = true
|
||||
}
|
||||
|
||||
|
||||
/** ========== 批量绑定套餐 ========== */
|
||||
const batchDialog = reactive({ visible: false, loading: false })
|
||||
|
||||
Reference in New Issue
Block a user