|
@@ -46,21 +46,28 @@
|
|
|
<el-image style="width: 80px; height: 80px" :src="scope.row.imgUrl" :preview-src-list="[scope.row.imgUrl]"> </el-image>
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
- <el-table-column label="图片类型" align="center" prop="bannerType">
|
|
|
- <template slot-scope="scope">
|
|
|
- <dict-tag :options="dict.type.app_banner_type" :value="scope.row.bannerType" />
|
|
|
- </template>
|
|
|
- </el-table-column>
|
|
|
+ <el-table-column label="标题" align="center" prop="redirectTitle" />
|
|
|
+ <!-- <el-table-column label="图片类型" align="center" prop="bannerType">-->
|
|
|
+ <!-- <template slot-scope="scope">-->
|
|
|
+ <!-- <dict-tag :options="dict.type.app_banner_type" :value="scope.row.bannerType" />-->
|
|
|
+ <!-- </template>-->
|
|
|
+ <!-- </el-table-column>-->
|
|
|
<el-table-column label="点击类型" align="center" prop="clickType">
|
|
|
<template slot-scope="scope">
|
|
|
<dict-tag :options="dict.type.app_banner_click_type" :value="scope.row.clickType" />
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
+
|
|
|
<el-table-column label="启用状态" align="center" prop="status">
|
|
|
<template slot-scope="scope">
|
|
|
<dict-tag :options="dict.type.sys_normal_disable" :value="scope.row.status" />
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
+ <el-table-column label="是否热销" align="center" prop="isHot" width="120" v-if="bannerType == 3">
|
|
|
+ <template slot-scope="scope">
|
|
|
+ <dict-tag :options="dict.type.sys_yes_no" :value="scope.row.isHot" />
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
<el-table-column label="创建人" align="center" prop="createBy" />
|
|
|
<el-table-column label="创建时间" align="center" prop="createTime" width="180" />
|
|
|
<el-table-column label="修改人" align="center" prop="updateBy" />
|
|
@@ -99,6 +106,11 @@
|
|
|
</el-radio-group>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
+ <el-col :span="24">
|
|
|
+ <el-form-item label="标题" prop="redirectTitle">
|
|
|
+ <el-input v-model="form.redirectTitle" placeholder="请输入标题" />
|
|
|
+ </el-form-item>
|
|
|
+ </el-col>
|
|
|
<el-col :span="24" v-if="form.clickType == '1'">
|
|
|
<el-form-item label="跳转内容" prop="redirectContent">
|
|
|
<el-input v-model="form.redirectContent" placeholder="请输入跳转网址" />
|
|
@@ -109,11 +121,18 @@
|
|
|
<editor v-model="form.redirectContent" :min-height="192" />
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
- <el-col :span="24" v-if="form.clickType == '3'">
|
|
|
- <el-form-item label="跳转内容" prop="redirectContent">
|
|
|
- <el-input v-model="form.redirectContent" placeholder="请输入内部页面路径" />
|
|
|
- </el-form-item>
|
|
|
- </el-col>
|
|
|
+ <el-col :span="24" v-if="form.clickType == '3'">
|
|
|
+ <el-form-item label="跳转内容" prop="redirectContent">
|
|
|
+ <el-input v-model="form.redirectContent" placeholder="请输入内部页面路径" />
|
|
|
+ </el-form-item>
|
|
|
+ </el-col>
|
|
|
+ <el-col :span="24" v-if="bannerType == 3">
|
|
|
+ <el-form-item label="是否热销" prop="isHot">
|
|
|
+ <el-radio-group v-model="form.isHot">
|
|
|
+ <el-radio-button v-for="dict in dict.type.sys_yes_no" :key="dict.value" :label="dict.value">{{ dict.label }}</el-radio-button>
|
|
|
+ </el-radio-group>
|
|
|
+ </el-form-item>
|
|
|
+ </el-col>
|
|
|
<el-col :span="24">
|
|
|
<el-form-item label="状态" prop="status">
|
|
|
<el-radio-group v-model="form.status" size="small">
|
|
@@ -136,7 +155,7 @@ import { listBanner, getBanner, delBanner, addBanner, updateBanner } from '@/api
|
|
|
|
|
|
export default {
|
|
|
name: 'Banner',
|
|
|
- dicts: ['app_banner_type', 'app_banner_click_type', 'sys_normal_disable'],
|
|
|
+ dicts: ['app_banner_type', 'app_banner_click_type', 'sys_yes_no', 'sys_normal_disable'],
|
|
|
data() {
|
|
|
return {
|
|
|
uploadAction: `${process.env.VUE_APP_BASE_API}` + '/common/uploadOSS',
|
|
@@ -169,7 +188,9 @@ export default {
|
|
|
updateById: null
|
|
|
},
|
|
|
// 表单参数
|
|
|
- form: {},
|
|
|
+ form: {
|
|
|
+ isHot: 'N'
|
|
|
+ },
|
|
|
// 表单校验
|
|
|
rules: {
|
|
|
bannerType: [
|