✨ 新增应收账单按角色和客户归属的行级数据权限

This commit is contained in:
caojia
2026-10-29 16:42:28 +08:00
parent b091d47f64
commit 02c49e3efe
30 changed files with 587 additions and 72 deletions
@@ -36,6 +36,11 @@ import { listCustomer, listCustomerOption } from '@/api/customersuppliermanageme
import { listSupplier } from '@/api/customersuppliermanagement/supplierinfo/supplier.js'
const props = defineProps({
// 业务页面可传入专用选项接口,默认行为保持不变。
fetchOptions: {
type: Function,
default: undefined
},
// 单选时为 String/Number;multiple 时为数组
modelValue: {
type: [String, Number, Array],
@@ -143,9 +148,9 @@ const displayOptions = computed(() => {
function fetchList(keyword = '') {
if (!props.remoteSearch && loaded.value) return Promise.resolve(options.value)
loading.value = true
const api = !isCustomer.value
const api = props.fetchOptions || (!isCustomer.value
? listSupplier
: (props.optionSelect ? listCustomerOption : listCustomer)
: (props.optionSelect ? listCustomerOption : listCustomer))
const currentRequest = ++requestSerial
const query = String(keyword || '').trim()
return api({