code review:banner 逻辑

(cherry picked from commit e5d6a9dae1)
This commit is contained in:
YunaiV 2023-10-24 20:07:48 +08:00 committed by shizhong
parent 11bc949309
commit 6ca92b9251
4 changed files with 6 additions and 41 deletions

View File

@ -185,7 +185,7 @@ export enum DICT_TYPE {
PROMOTION_CONDITION_TYPE = 'promotion_condition_type', // 营销的条件类型枚举 PROMOTION_CONDITION_TYPE = 'promotion_condition_type', // 营销的条件类型枚举
PROMOTION_BARGAIN_RECORD_STATUS = 'promotion_bargain_record_status', // 砍价记录的状态 PROMOTION_BARGAIN_RECORD_STATUS = 'promotion_bargain_record_status', // 砍价记录的状态
PROMOTION_COMBINATION_RECORD_STATUS = 'promotion_combination_record_status', // 拼团记录的状态 PROMOTION_COMBINATION_RECORD_STATUS = 'promotion_combination_record_status', // 拼团记录的状态
BANNER_POSITION = 'banner_position', // banner 定位 PROMOTION_BANNER_POSITION = 'promotion_banner_position', // banner 定位
// ========== CRM - 客户管理模块 ========== // ========== CRM - 客户管理模块 ==========
CRM_RECEIVABLE_CHECK_STATUS = 'crm_receivable_check_status', CRM_RECEIVABLE_CHECK_STATUS = 'crm_receivable_check_status',

View File

@ -109,59 +109,24 @@ const props = defineProps({
const promotionTypes = ref<DictDataType[]>([ const promotionTypes = ref<DictDataType[]>([
{ {
dictType: 'promotionTypes', dictType: 'promotionTypes',
label: '秒杀活动', label: '秒杀',
value: 1, value: 1,
colorType: 'warning', colorType: 'warning',
cssClass: '' cssClass: ''
}, },
{ {
dictType: 'promotionTypes', dictType: 'promotionTypes',
label: '砍价活动', label: '砍价',
value: 2, value: 2,
colorType: 'warning', colorType: 'warning',
cssClass: '' cssClass: ''
}, },
{ {
dictType: 'promotionTypes', dictType: 'promotionTypes',
label: '拼团活动', label: '拼团',
value: 3, value: 3,
colorType: 'warning', colorType: 'warning',
cssClass: '' cssClass: ''
},
{
dictType: 'promotionTypes',
label: '限时折扣',
value: 4,
colorType: 'warning',
cssClass: ''
},
{
dictType: 'promotionTypes',
label: '满减送',
value: 5,
colorType: 'warning',
cssClass: ''
},
{
dictType: 'promotionTypes',
label: '会员折扣',
value: 6,
colorType: 'warning',
cssClass: ''
},
{
dictType: 'promotionTypes',
label: '优惠劵',
value: 7,
colorType: 'warning',
cssClass: ''
},
{
dictType: 'promotionTypes',
label: '积分',
value: 8,
colorType: 'warning',
cssClass: ''
} }
]) ])

View File

@ -45,7 +45,7 @@
<el-form-item label="定位" prop="position"> <el-form-item label="定位" prop="position">
<el-radio-group v-model="formData.position"> <el-radio-group v-model="formData.position">
<el-radio <el-radio
v-for="dict in getIntDictOptions(DICT_TYPE.BANNER_POSITION)" v-for="dict in getIntDictOptions(DICT_TYPE.PROMOTION_BANNER_POSITION)"
:key="dict.value" :key="dict.value"
:label="dict.value" :label="dict.value"
> >

View File

@ -76,7 +76,7 @@
</el-table-column> </el-table-column>
<el-table-column align="center" label="定位" prop="position"> <el-table-column align="center" label="定位" prop="position">
<template #default="scope"> <template #default="scope">
<dict-tag :type="DICT_TYPE.BANNER_POSITION" :value="scope.row.position" /> <dict-tag :type="DICT_TYPE.PROMOTION_BANNER_POSITION" :value="scope.row.position" />
</template> </template>
</el-table-column> </el-table-column>
<el-table-column align="center" label="跳转地址" prop="url" /> <el-table-column align="center" label="跳转地址" prop="url" />