Commit 065d09dd authored by 杨硕's avatar 杨硕
parents bdf0d9b4 0eb46d07
...@@ -3,7 +3,7 @@ import request from '@/utils/request' ...@@ -3,7 +3,7 @@ import request from '@/utils/request'
// 获取金额和积分的列表 // 获取金额和积分的列表
export function queryIntegralList(params) { export function queryIntegralList(params) {
return request({ return request({
url: '/system/integral//queryintergras', url: '/system/integral/queryintergras',
method: 'get', method: 'get',
params params
}) })
...@@ -30,7 +30,7 @@ export function queryInfoById(id) { ...@@ -30,7 +30,7 @@ export function queryInfoById(id) {
// 编辑金额和积分的数据 // 编辑金额和积分的数据
export function updataInfo(data) { export function updataInfo(data) {
return request({ return request({
url: '/system/integral//update', url: '/system/integral/update',
method: 'put', method: 'put',
data, data,
headers: { headers: {
...@@ -61,7 +61,7 @@ export function queryMemberLevel() { ...@@ -61,7 +61,7 @@ export function queryMemberLevel() {
}) })
} }
// 新增会员等级 // 新增会员等级
export function addMemberBenefits(data){ export function addMemberBenefits(data) {
return request({ return request({
url: '/system/memberfits/add', url: '/system/memberfits/add',
method: 'put', method: 'put',
......
...@@ -47,14 +47,15 @@ ...@@ -47,14 +47,15 @@
:limit="1" :limit="1"
list-type="picture" list-type="picture"
> >
<img v-if="imgUrl" :src="imgUrl" class="avatar">
<!-- <el-button size="small" type="primary">点击上传</el-button>--> <!-- <el-button size="small" type="primary">点击上传</el-button>-->
<div class="upload-trademark"> <div v-if="!imgUrl" class="upload-trademark">
<i class="el-icon-plus" style="width: 20px;height: 20px;margin-top: 10px;" /> <i class="el-icon-plus" style="width: 20px;height: 20px;margin-top: 10px;" />
<div class="upload-trademark-title">上传竖版封面</div></div> <div class="upload-trademark-title">上传竖版封面</div></div>
<div slot="tip" class="el-upload__tip">支持文件格式:.jpg .gpeg .png.单个文件不能超过4M</div> <div v-if="!imgUrl" slot="tip" class="el-upload__tip">支持文件格式:.jpg .gpeg .png.单个文件不能超过4M</div>
</el-upload> </el-upload>
</el-form-item> </el-form-item>
<el-form-item label="封面" prop="image"> <el-form-item label="横版封面" prop="image">
<el-upload <el-upload
class="upload-image" class="upload-image"
action="#" action="#"
...@@ -135,7 +136,7 @@ export default { ...@@ -135,7 +136,7 @@ export default {
} }
}, },
created() { created() {
// const baseURL = 'http://192.144.239.97:20043/file/' const baseURL = 'http://192.144.239.97:20043/file/'
if (this.type === 0) { if (this.type === 0) {
this.form = {} this.form = {}
} else if (this.type === 1) { } else if (this.type === 1) {
...@@ -144,6 +145,8 @@ export default { ...@@ -144,6 +145,8 @@ export default {
queryDetailById(id).then(res => { queryDetailById(id).then(res => {
if (res.code === 200) { if (res.code === 200) {
this.form = res.data this.form = res.data
this.imgUrl = baseURL + this.form.imgUrl
this.imgageUrl = baseURL + this.form.imageUrl
console.log('form', this.form) console.log('form', this.form)
} }
}) })
......
This diff is collapsed.
...@@ -107,7 +107,7 @@ ...@@ -107,7 +107,7 @@
{{ scope.row.dealTime || '-' }} {{ scope.row.dealTime || '-' }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="操作" class-name="small-padding fixed-width" width="240"> <el-table-column label="操作" class-name="small-padding fixed-width" width="120">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button <el-button
v-hasPermi="['sys:dict:edit']" v-hasPermi="['sys:dict:edit']"
...@@ -549,6 +549,9 @@ export default { ...@@ -549,6 +549,9 @@ export default {
.el-switch .el-switch__label { .el-switch .el-switch__label {
width: 57px!important; width: 57px!important;
} }
::v-deep .el-table td .cell{
height: 48px;
}
</style> </style>
<style lang="scss"> <style lang="scss">
.app-container-dict { .app-container-dict {
......
<template> <template>
<div class="equityseting"> <div class="equityseting">
<div class="equityseting-title">会员权益设定</div>
<div class="form1"> <div class="form1">
<div style="margin-bottom: 20px;display: flex;justify-content: space-between"> <div style="margin-bottom: 20px;display: flex;justify-content: space-between">
<div>会员等级</div> <h5
style="margin: 0 0 12px 0;font-size: 14px;font-weight: bold;
color: #333333;"
>会员等级</h5>
<el-button type="primary" icon="el-icon-plus" @click="addDomain">新增</el-button> <el-button type="primary" icon="el-icon-plus" @click="addDomain">新增</el-button>
</div> </div>
<el-table border :data="membershiplevel"> <el-table border :data="membershiplevel">
...@@ -19,17 +21,17 @@ ...@@ -19,17 +21,17 @@
{{ scope.row.level || '-' }} {{ scope.row.level || '-' }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="积分条件" prop="integral" :show-overflow-tooltip="true"> <el-table-column label="所需积分" prop="integral" :show-overflow-tooltip="true">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.integral || '-' }} {{ scope.row.integral || '-' }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="折扣" prop="discount" :show-overflow-tooltip="true"> <el-table-column label="享受折扣" prop="discount" :show-overflow-tooltip="true">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.discount || '-' }} {{ scope.row.discount || '-' }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="操作" class-name="small-padding fixed-width" width="240"> <el-table-column label="操作" class-name="small-padding fixed-width" width="120">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button <el-button
v-hasPermi="['sys:dict:remove']" v-hasPermi="['sys:dict:remove']"
...@@ -50,7 +52,10 @@ ...@@ -50,7 +52,10 @@
</el-table> </el-table>
<el-divider style="margin-top: 53px" /> <el-divider style="margin-top: 53px" />
<div style="margin-bottom: 20px;display: flex;justify-content: space-between"> <div style="margin-bottom: 20px;display: flex;justify-content: space-between">
<div>积分兑换</div> <h5
style="margin: 0 0 12px 0;font-size: 14px;font-weight: bold;
color: #333333;"
>获取积分</h5>
<el-button type="primary" icon="el-icon-plus" @click="addDynamic">新增</el-button> <el-button type="primary" icon="el-icon-plus" @click="addDynamic">新增</el-button>
</div> </div>
<el-table border :data="dynamicValidate"> <el-table border :data="dynamicValidate">
...@@ -61,12 +66,12 @@ ...@@ -61,12 +66,12 @@
<span>{{ scope.row.amount || '' }}</span> <span>{{ scope.row.amount || '' }}</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="兑换积分" prop="level" :show-overflow-tooltip="true"> <el-table-column label="获取积分" prop="level" :show-overflow-tooltip="true">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.integral || '-' }} {{ scope.row.integral || '-' }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="操作" class-name="small-padding fixed-width" width="240"> <el-table-column label="操作" class-name="small-padding fixed-width" width="120">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button <el-button
v-hasPermi="['sys:dict:remove']" v-hasPermi="['sys:dict:remove']"
...@@ -100,12 +105,12 @@ ...@@ -100,12 +105,12 @@
<el-form-item prop="level" label="会员等级"> <el-form-item prop="level" label="会员等级">
<el-input v-model="form.level" disabled placeholder="请输入会员等级" :maxlength="10" /> <el-input v-model="form.level" disabled placeholder="请输入会员等级" :maxlength="10" />
</el-form-item> </el-form-item>
<el-form-item prop="integral" label="积分条件"> <el-form-item prop="integral" label="所需积分">
<el-input v-model="form.integral" placeholder="请输入积分条件" :maxlength="10" /> <el-input v-model="form.integral" placeholder="请输入所需积分" :maxlength="10" />
</el-form-item> </el-form-item>
<el-form-item prop="discount" label="折扣"> <el-form-item prop="discount" label="享受折扣">
<div style="display:flex;"> <div style="display:flex;">
<el-input v-model="form.discount" placeholder="请输入折扣" :maxlength="10" /> <el-input v-model="form.discount" placeholder="请输入享受折扣" :maxlength="10" />
<span style="margin-left: 12px">{{ '%' }}</span> <span style="margin-left: 12px">{{ '%' }}</span>
</div> </div>
</el-form-item> </el-form-item>
...@@ -125,8 +130,8 @@ ...@@ -125,8 +130,8 @@
:maxlength="10" :maxlength="10"
/> />
</el-form-item> </el-form-item>
<el-form-item prop="integral" label="兑换积分"> <el-form-item prop="integral" label="获取积分">
<el-input v-model="dynamicFrom.integral" placeholder="请输入兑换积分" :maxlength="10" /> <el-input v-model="dynamicFrom.integral" placeholder="请输入获取积分" :maxlength="10" />
</el-form-item> </el-form-item>
<div style="text-align: center"> <div style="text-align: center">
<el-button type="primary" @click="dynamicsubmitForm">提交</el-button> <el-button type="primary" @click="dynamicsubmitForm">提交</el-button>
...@@ -226,7 +231,7 @@ export default { ...@@ -226,7 +231,7 @@ export default {
this.opens = false this.opens = false
}, },
addDynamic() { addDynamic() {
this.dynamicTitle = '新增积分兑换' this.dynamicTitle = '新增获取积分'
this.dynamicFrom = { this.dynamicFrom = {
amount: '', amount: '',
integral: '' integral: ''
...@@ -401,7 +406,7 @@ export default { ...@@ -401,7 +406,7 @@ export default {
}, },
// 兑换积分编辑 // 兑换积分编辑
dynamicUpdate(row) { dynamicUpdate(row) {
this.dynamicTitle = '编辑兑换积分' this.dynamicTitle = '编辑获取积分'
const id = row.businessId const id = row.businessId
queryInfoById(id).then(res => { queryInfoById(id).then(res => {
console.log('查询信息', res) console.log('查询信息', res)
......
...@@ -81,9 +81,14 @@ ...@@ -81,9 +81,14 @@
{{ scope.row.nickName || '-' }} {{ scope.row.nickName || '-' }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="积分" prop="integral" :show-overflow-tooltip="true"> <el-table-column label="用户性别" prop="sex" :show-overflow-tooltip="true">
<template slot-scope="scope">
{{ replaceSex(scope.row.sex) || '-' }}
</template>
</el-table-column>
<el-table-column label="用户邮箱" prop="email" :show-overflow-tooltip="true">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.integral || '-' }} {{ scope.row.email || '-' }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="level" label="会员等级" :show-overflow-tooltip="true"> <el-table-column prop="level" label="会员等级" :show-overflow-tooltip="true">
...@@ -91,12 +96,17 @@ ...@@ -91,12 +96,17 @@
{{ scope.row.level || '-' }} {{ scope.row.level || '-' }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="积分" prop="integral" :show-overflow-tooltip="true">
<template slot-scope="scope">
{{ scope.row.integral || '-' }}
</template>
</el-table-column>
<el-table-column label="报名活动数" prop="count" :show-overflow-tooltip="true"> <el-table-column label="报名活动数" prop="count" :show-overflow-tooltip="true">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.count || '-' }} {{ scope.row.count || '-' }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="操作" class-name="small-padding fixed-width" width="240"> <el-table-column label="操作" class-name="small-padding fixed-width" width="100">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button <el-button
v-hasPermi="['sys:dict:edit']" v-hasPermi="['sys:dict:edit']"
...@@ -256,10 +266,17 @@ export default { ...@@ -256,10 +266,17 @@ export default {
// }) // })
}, },
methods: { methods: {
replaceSex(value) {
if (value === '0') {
return '女'
} else {
return '男'
}
},
replaceImg(value) { replaceImg(value) {
console.log('img', value) console.log('img', value)
if (value === '') { if (value === '') {
return 'https://cube.elemecdn.com/3/7c/3ea6beec64369c2642b92c6726f1epng.png' return 'http://192.144.239.97:20043/file/static/images/login/denglu_icon_logo.png'
} else { } else {
return value return value
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment