套餐系列:梯度佣金,代理授权
All checks were successful
构建并部署前端到测试环境 / build-and-deploy (push) Successful in 4m47s
All checks were successful
构建并部署前端到测试环境 / build-and-deploy (push) Successful in 4m47s
This commit is contained in:
@@ -170,6 +170,11 @@
|
||||
<template v-if="form.commission_type === 'tiered'">
|
||||
<ElFormItem label="梯度配置" prop="commission_tiers">
|
||||
<ElTable :data="form.commission_tiers" border style="width: 100%">
|
||||
<ElTableColumn label="比较运算符" width="100" align="center">
|
||||
<template #default="{ row }">
|
||||
<ElTag size="small" type="success">{{ row.operator || '>=' }}</ElTag>
|
||||
</template>
|
||||
</ElTableColumn>
|
||||
<ElTableColumn label="达标阈值" width="120">
|
||||
<template #default="{ row }">
|
||||
<span class="readonly-value">{{ row.threshold }}</span>
|
||||
@@ -504,6 +509,7 @@
|
||||
one_time_commission_amount: 0, // 固定佣金金额(元)
|
||||
series_max_commission_amount: 0, // 系列最大佣金金额(元)
|
||||
commission_tiers: [] as Array<{
|
||||
operator?: '>=' | '>' | '<=' | '<' // 比较运算符
|
||||
threshold: number // 达标阈值
|
||||
dimension: 'sales_count' | 'sales_amount' // 统计维度
|
||||
stat_scope?: 'self' | 'self_and_sub' // 统计范围
|
||||
@@ -848,6 +854,7 @@
|
||||
// 梯度配置从系列继承,包含完整字段,佣金金额也默认继承
|
||||
if (commissionConfig.tiers && commissionConfig.tiers.length > 0) {
|
||||
form.commission_tiers = commissionConfig.tiers.map((tier) => ({
|
||||
operator: tier.operator || '>=', // 比较运算符(只读)
|
||||
threshold: tier.threshold, // 达标阈值(只读)
|
||||
dimension: tier.dimension, // 统计维度(只读)
|
||||
stat_scope: tier.stat_scope, // 统计范围(只读)
|
||||
@@ -1153,6 +1160,7 @@
|
||||
form.commission_tiers = detail.commission_tiers.map((tier, index) => {
|
||||
const seriesTier = seriesTiers[index]
|
||||
return {
|
||||
operator: tier.operator || seriesTier?.operator || '>=', // 比较运算符(只读,优先使用授权的,否则从系列获取)
|
||||
threshold: tier.threshold, // 达标阈值(只读)
|
||||
dimension: seriesTier?.dimension || 'sales_count', // 统计维度(只读,从系列获取)
|
||||
stat_scope: seriesTier?.stat_scope, // 统计范围(只读,从系列获取)
|
||||
|
||||
Reference in New Issue
Block a user