会员信息接口联调
This commit is contained in:
parent
ea57595738
commit
a9a7b681cb
@ -1,4 +1,4 @@
|
|||||||
import request from '@/utils/request'
|
import request from '@/utils/request';
|
||||||
|
|
||||||
// 查询会员信息列表
|
// 查询会员信息列表
|
||||||
export function listUmsMember(query, pageReq) {
|
export function listUmsMember(query, pageReq) {
|
||||||
@ -7,7 +7,7 @@ export function listUmsMember(query, pageReq) {
|
|||||||
method: 'post',
|
method: 'post',
|
||||||
data: query,
|
data: query,
|
||||||
params: pageReq
|
params: pageReq
|
||||||
})
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
// 查询会员信息详细
|
// 查询会员信息详细
|
||||||
@ -15,7 +15,7 @@ export function getUmsMember(id) {
|
|||||||
return request({
|
return request({
|
||||||
url: '/ums/member/' + id,
|
url: '/ums/member/' + id,
|
||||||
method: 'get'
|
method: 'get'
|
||||||
})
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
// 新增会员信息
|
// 新增会员信息
|
||||||
@ -24,7 +24,7 @@ export function addUmsMember(data) {
|
|||||||
url: '/ums/member',
|
url: '/ums/member',
|
||||||
method: 'post',
|
method: 'post',
|
||||||
data: data
|
data: data
|
||||||
})
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
// 修改会员信息
|
// 修改会员信息
|
||||||
@ -33,14 +33,14 @@ export function updateUmsMember(data) {
|
|||||||
url: '/ums/member',
|
url: '/ums/member',
|
||||||
method: 'put',
|
method: 'put',
|
||||||
data: data
|
data: data
|
||||||
})
|
});
|
||||||
}
|
}
|
||||||
export function updateUmsMemberMark(data) {
|
export function updateUmsMemberMark(data) {
|
||||||
return request({
|
return request({
|
||||||
url: '/ums/member/mark/update',
|
url: '/ums/member/mark/update',
|
||||||
method: 'post',
|
method: 'post',
|
||||||
data: data
|
data: data
|
||||||
})
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
// 删除会员信息
|
// 删除会员信息
|
||||||
@ -48,7 +48,7 @@ export function delUmsMember(id) {
|
|||||||
return request({
|
return request({
|
||||||
url: '/ums/member/' + id,
|
url: '/ums/member/' + id,
|
||||||
method: 'delete'
|
method: 'delete'
|
||||||
})
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
// 导出会员信息
|
// 导出会员信息
|
||||||
@ -57,7 +57,7 @@ export function exportUmsMember(query) {
|
|||||||
url: '/ums/member/export',
|
url: '/ums/member/export',
|
||||||
method: 'get',
|
method: 'get',
|
||||||
params: query
|
params: query
|
||||||
})
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
// 更改会员账号状态
|
// 更改会员账号状态
|
||||||
@ -66,7 +66,7 @@ export function changeAccountStatus(data) {
|
|||||||
url: '/ums/member/status/change',
|
url: '/ums/member/status/change',
|
||||||
method: 'post',
|
method: 'post',
|
||||||
data: data
|
data: data
|
||||||
})
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
// 获取解密手机号
|
// 获取解密手机号
|
||||||
@ -74,7 +74,7 @@ export function decryptedPhone(data) {
|
|||||||
return request({
|
return request({
|
||||||
url: `/ums/member/phone/decrypt/` + data,
|
url: `/ums/member/phone/decrypt/` + data,
|
||||||
method: 'get'
|
method: 'get'
|
||||||
})
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
// 查询会员统计数据
|
// 查询会员统计数据
|
||||||
@ -82,7 +82,7 @@ export function viewStatistics(memberId) {
|
|||||||
return request({
|
return request({
|
||||||
url: `/ums/member/view/statistics/` + memberId,
|
url: `/ums/member/view/statistics/` + memberId,
|
||||||
method: 'get'
|
method: 'get'
|
||||||
})
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
export function getMiniWechatImg(params) {
|
export function getMiniWechatImg(params) {
|
||||||
@ -90,7 +90,7 @@ export function getMiniWechatImg(params) {
|
|||||||
url: `/ums/member/wechat/code`,
|
url: `/ums/member/wechat/code`,
|
||||||
method: 'get',
|
method: 'get',
|
||||||
params
|
params
|
||||||
})
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
export function judgeQrCode(params) {
|
export function judgeQrCode(params) {
|
||||||
@ -98,7 +98,40 @@ export function judgeQrCode(params) {
|
|||||||
url: `/no-auth/verified/code`,
|
url: `/no-auth/verified/code`,
|
||||||
method: 'get',
|
method: 'get',
|
||||||
params
|
params
|
||||||
})
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 查询会员信息账号详情
|
||||||
|
export function getUserAccountInfo(memberId) {
|
||||||
|
return request({
|
||||||
|
url: `/ums/member/account/${memberId}`,
|
||||||
|
method: 'get'
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
// 会员登录详情
|
||||||
|
export function getUserLoginInfoData(data) {
|
||||||
|
return request({
|
||||||
|
url: `/ums/member/loginInfo/list`,
|
||||||
|
method: 'post',
|
||||||
|
data: data
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
// 会改会员状态
|
||||||
|
export function upDateMemberStatus(data) {
|
||||||
|
return request({
|
||||||
|
url: `/ums/member/status/change`,
|
||||||
|
method: 'post',
|
||||||
|
data: data
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
// 编辑会员基础信息
|
||||||
|
export function editUserData(data) {
|
||||||
|
return request({
|
||||||
|
url: `/ums/member/update`,
|
||||||
|
method: 'post',
|
||||||
|
data: data
|
||||||
|
});
|
||||||
|
}
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
<template>
|
<template>
|
||||||
<div :class="{'show':show}" class="header-search">
|
<div :class="{ 'show': show }" class="header-search">
|
||||||
<svg-icon class-name="search-icon" icon-class="search" @click.stop="click" />
|
<svg-icon class-name="search-icon" icon-class="search" @click.stop="click" />
|
||||||
<el-select
|
<el-select
|
||||||
ref="headerSearchSelect"
|
ref="headerSearchSelect"
|
||||||
@ -20,8 +20,8 @@
|
|||||||
<script>
|
<script>
|
||||||
// fuse is a lightweight fuzzy-search module
|
// fuse is a lightweight fuzzy-search module
|
||||||
// make search results more in line with expectations
|
// make search results more in line with expectations
|
||||||
import Fuse from 'fuse.js/dist/fuse.min.js'
|
import Fuse from 'fuse.js/dist/fuse.min.js';
|
||||||
import path from 'path'
|
import path from 'path';
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'HeaderSearch',
|
name: 'HeaderSearch',
|
||||||
@ -32,57 +32,57 @@ export default {
|
|||||||
searchPool: [],
|
searchPool: [],
|
||||||
show: false,
|
show: false,
|
||||||
fuse: undefined
|
fuse: undefined
|
||||||
}
|
};
|
||||||
},
|
},
|
||||||
computed: {
|
computed: {
|
||||||
routes() {
|
routes() {
|
||||||
return this.$store.getters.permission_routes
|
return this.$store.getters.permission_routes;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
watch: {
|
watch: {
|
||||||
routes() {
|
routes() {
|
||||||
this.searchPool = this.generateRoutes(this.routes)
|
this.searchPool = this.generateRoutes(this.routes);
|
||||||
},
|
},
|
||||||
searchPool(list) {
|
searchPool(list) {
|
||||||
this.initFuse(list)
|
this.initFuse(list);
|
||||||
},
|
},
|
||||||
show(value) {
|
show(value) {
|
||||||
if (value) {
|
if (value) {
|
||||||
document.body.addEventListener('click', this.close)
|
document.body.addEventListener('click', this.close);
|
||||||
} else {
|
} else {
|
||||||
document.body.removeEventListener('click', this.close)
|
document.body.removeEventListener('click', this.close);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
this.searchPool = this.generateRoutes(this.routes)
|
this.searchPool = this.generateRoutes(this.routes);
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
click() {
|
click() {
|
||||||
this.show = !this.show
|
this.show = !this.show;
|
||||||
if (this.show) {
|
if (this.show) {
|
||||||
this.$refs.headerSearchSelect && this.$refs.headerSearchSelect.focus()
|
this.$refs.headerSearchSelect && this.$refs.headerSearchSelect.focus();
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
close() {
|
close() {
|
||||||
this.$refs.headerSearchSelect && this.$refs.headerSearchSelect.blur()
|
this.$refs.headerSearchSelect && this.$refs.headerSearchSelect.blur();
|
||||||
this.options = []
|
this.options = [];
|
||||||
this.show = false
|
this.show = false;
|
||||||
},
|
},
|
||||||
change(val) {
|
change(val) {
|
||||||
const path = val.path;
|
const path = val.path;
|
||||||
if(this.ishttp(val.path)) {
|
if (this.ishttp(val.path)) {
|
||||||
// http(s):// 路径新窗口打开
|
// http(s):// 路径新窗口打开
|
||||||
const pindex = path.indexOf("http");
|
const pindex = path.indexOf('http');
|
||||||
window.open(path.substr(pindex, path.length), "_blank");
|
window.open(path.substr(pindex, path.length), '_blank');
|
||||||
} else {
|
} else {
|
||||||
this.$router.push(val.path)
|
this.$router.push(val.path);
|
||||||
}
|
}
|
||||||
this.search = ''
|
this.search = '';
|
||||||
this.options = []
|
this.options = [];
|
||||||
this.$nextTick(() => {
|
this.$nextTick(() => {
|
||||||
this.show = false
|
this.show = false;
|
||||||
})
|
});
|
||||||
},
|
},
|
||||||
initFuse(list) {
|
initFuse(list) {
|
||||||
this.fuse = new Fuse(list, {
|
this.fuse = new Fuse(list, {
|
||||||
@ -92,61 +92,66 @@ export default {
|
|||||||
distance: 100,
|
distance: 100,
|
||||||
maxPatternLength: 32,
|
maxPatternLength: 32,
|
||||||
minMatchCharLength: 1,
|
minMatchCharLength: 1,
|
||||||
keys: [{
|
keys: [
|
||||||
|
{
|
||||||
name: 'title',
|
name: 'title',
|
||||||
weight: 0.7
|
weight: 0.7
|
||||||
}, {
|
},
|
||||||
|
{
|
||||||
name: 'path',
|
name: 'path',
|
||||||
weight: 0.3
|
weight: 0.3
|
||||||
}]
|
}
|
||||||
})
|
]
|
||||||
|
});
|
||||||
},
|
},
|
||||||
// Filter out the routes that can be displayed in the sidebar
|
// Filter out the routes that can be displayed in the sidebar
|
||||||
// And generate the internationalized title
|
// And generate the internationalized title
|
||||||
generateRoutes(routes, basePath = '/', prefixTitle = []) {
|
generateRoutes(routes, basePath = '/', prefixTitle = []) {
|
||||||
let res = []
|
let res = [];
|
||||||
|
|
||||||
for (const router of routes) {
|
for (const router of routes) {
|
||||||
// skip hidden router
|
// skip hidden router
|
||||||
if (router.hidden) { continue }
|
if (router.hidden) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
const data = {
|
const data = {
|
||||||
path: !this.ishttp(router.path) ? path.resolve(basePath, router.path) : router.path,
|
path: !this.ishttp(router.path) ? path.resolve(basePath, router.path) : router.path,
|
||||||
title: [...prefixTitle]
|
title: [...prefixTitle]
|
||||||
}
|
};
|
||||||
|
|
||||||
if (router.meta && router.meta.title) {
|
if (router.meta && router.meta.title) {
|
||||||
data.title = [...data.title, router.meta.title]
|
data.title = [...data.title, router.meta.title];
|
||||||
|
|
||||||
if (router.redirect !== 'noRedirect') {
|
if (router.redirect !== 'noRedirect') {
|
||||||
// only push the routes with title
|
// only push the routes with title
|
||||||
// special case: need to exclude parent router without redirect
|
// special case: need to exclude parent router without redirect
|
||||||
res.push(data)
|
res.push(data);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// recursive child routes
|
// recursive child routes
|
||||||
if (router.children) {
|
if (router.children) {
|
||||||
const tempRoutes = this.generateRoutes(router.children, data.path, data.title)
|
const tempRoutes = this.generateRoutes(router.children, data.path, data.title);
|
||||||
if (tempRoutes.length >= 1) {
|
if (tempRoutes.length >= 1) {
|
||||||
res = [...res, ...tempRoutes]
|
res = [...res, ...tempRoutes];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return res
|
return res;
|
||||||
},
|
},
|
||||||
querySearch(query) {
|
querySearch(query) {
|
||||||
if (query !== '') {
|
if (query !== '') {
|
||||||
this.options = this.fuse.search(query)
|
this.options = this.fuse.search(query);
|
||||||
} else {
|
} else {
|
||||||
this.options = []
|
this.options = [];
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
ishttp(url) {
|
ishttp(url) {
|
||||||
return url.indexOf('http://') !== -1 || url.indexOf('https://') !== -1
|
return url.indexOf('http://') !== -1 || url.indexOf('https://') !== -1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
|
@ -50,7 +50,7 @@ export default {
|
|||||||
if (res) {
|
if (res) {
|
||||||
this.open = false;
|
this.open = false;
|
||||||
} else {
|
} else {
|
||||||
this.$message.error('验证码错误');
|
this.$modal.msgError('验证码错误');
|
||||||
}
|
}
|
||||||
this.$emit('confirmOk', res);
|
this.$emit('confirmOk', res);
|
||||||
}
|
}
|
||||||
|
@ -58,8 +58,6 @@ export const usePermissionStore = defineStore('permission', () => {
|
|||||||
asyncRoutes.forEach((route) => {
|
asyncRoutes.forEach((route) => {
|
||||||
router.addRoute(route);
|
router.addRoute(route);
|
||||||
});
|
});
|
||||||
console.info('1111111111111111', asyncRoutes);
|
|
||||||
console.info('222222222222222222', router);
|
|
||||||
setRoutes(rewriteRoutes);
|
setRoutes(rewriteRoutes);
|
||||||
setSidebarRouters(constantRoutes.concat(sidebarRoutes));
|
setSidebarRouters(constantRoutes.concat(sidebarRoutes));
|
||||||
setDefaultRoutes(sidebarRoutes);
|
setDefaultRoutes(sidebarRoutes);
|
||||||
|
@ -378,7 +378,7 @@ export default {
|
|||||||
this.updateOrderForm.optType = type;
|
this.updateOrderForm.optType = type;
|
||||||
dealWithAftersale(this.updateOrderForm).then((response) => {
|
dealWithAftersale(this.updateOrderForm).then((response) => {
|
||||||
this.cancel();
|
this.cancel();
|
||||||
this.$message.success('操作成功');
|
this.$modal.msgSuccess('操作成功');
|
||||||
this.getList();
|
this.getList();
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
@ -396,7 +396,7 @@ export default {
|
|||||||
this.updateOrderForm.optType = type;
|
this.updateOrderForm.optType = type;
|
||||||
dealWithAftersale(this.updateOrderForm).then((response) => {
|
dealWithAftersale(this.updateOrderForm).then((response) => {
|
||||||
this.cancel();
|
this.cancel();
|
||||||
this.$message.success('操作成功');
|
this.$modal.msgSuccess('操作成功');
|
||||||
this.getList();
|
this.getList();
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
@ -460,7 +460,7 @@ export default {
|
|||||||
this.$confirm(`您确定要拒绝售后单号为【${this.updateOrderForm.id}】的售后申请了吗?`, '温馨提示', { type: 'warning' }).then(() => {
|
this.$confirm(`您确定要拒绝售后单号为【${this.updateOrderForm.id}】的售后申请了吗?`, '温馨提示', { type: 'warning' }).then(() => {
|
||||||
dealWithAftersale(this.updateOrderForm).then((response) => {
|
dealWithAftersale(this.updateOrderForm).then((response) => {
|
||||||
this.cancel();
|
this.cancel();
|
||||||
this.$message.success('操作成功');
|
this.$modal.msgSuccess('操作成功');
|
||||||
this.getList();
|
this.getList();
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
@ -597,9 +597,10 @@ export default {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
getOrderStatusText(status) {
|
getOrderStatusText(status) {
|
||||||
const { label = '' } = this.orderStatusMap.find((item) => {
|
const { label = '' } =
|
||||||
|
this.orderStatusMap.find((item) => {
|
||||||
return item.value == status;
|
return item.value == status;
|
||||||
});
|
}) || {};
|
||||||
return label || '未知';
|
return label || '未知';
|
||||||
},
|
},
|
||||||
getLogEvent(status) {
|
getLogEvent(status) {
|
||||||
|
@ -233,7 +233,7 @@ export default {
|
|||||||
/** 删除按钮操作 */
|
/** 删除按钮操作 */
|
||||||
handleDelete(row) {
|
handleDelete(row) {
|
||||||
if (row.children && row.children.length > 0) {
|
if (row.children && row.children.length > 0) {
|
||||||
this.$message.error('请先删除子目录');
|
this.$modal.msgError('请先删除子目录');
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
const ids = row.id;
|
const ids = row.id;
|
||||||
|
@ -59,7 +59,7 @@ export default {
|
|||||||
},
|
},
|
||||||
asyncOk() {
|
asyncOk() {
|
||||||
addOrUpdate(this.currentConfig).then((res) => {
|
addOrUpdate(this.currentConfig).then((res) => {
|
||||||
this.$message.success('保存成功');
|
this.$modal.msgSuccess('保存成功');
|
||||||
this.getData();
|
this.getData();
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
@ -150,13 +150,13 @@ export default {
|
|||||||
updateRemark() {
|
updateRemark() {
|
||||||
updateMark({ id: this.remarkModal.id, remark: this.remarkModal.remark }).then((res) => {
|
updateMark({ id: this.remarkModal.id, remark: this.remarkModal.remark }).then((res) => {
|
||||||
if (res > 0) {
|
if (res > 0) {
|
||||||
this.$message.success('修改成功');
|
this.$modal.msgSuccess('修改成功');
|
||||||
this.remarkModal.visible = false;
|
this.remarkModal.visible = false;
|
||||||
const obj = this.feedbackList.filter((it) => it.id === this.remarkModal.id)[0];
|
const obj = this.feedbackList.filter((it) => it.id === this.remarkModal.id)[0];
|
||||||
console.log(111, obj, this.remarkModal.remark);
|
console.log(111, obj, this.remarkModal.remark);
|
||||||
obj.remark = this.remarkModal.remark;
|
obj.remark = this.remarkModal.remark;
|
||||||
} else {
|
} else {
|
||||||
this.$message.error('修改失败');
|
this.$modal.msgError('修改失败');
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
@ -207,7 +207,7 @@ export default {
|
|||||||
};
|
};
|
||||||
changeHandleStatus(data).then((response) => {
|
changeHandleStatus(data).then((response) => {
|
||||||
if (response) {
|
if (response) {
|
||||||
this.$message.success('操作成功');
|
this.$modal.msgSuccess('操作成功');
|
||||||
this.getList();
|
this.getList();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
@ -16,14 +16,9 @@
|
|||||||
end-placeholder="结束日期"
|
end-placeholder="结束日期"
|
||||||
></el-date-picker>
|
></el-date-picker>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<!-- <el-form-item label="账号启用状态">-->
|
<el-form-item label="会员ID" prop="id">
|
||||||
<!-- <el-select v-model="queryParams.status" placeholder="请选择" :clearable="true" size="small">-->
|
<el-input v-model.trim="queryParams.id" placeholder="请输入会员id" clearable size="small" />
|
||||||
<!-- <el-option label="禁用" value="0">-->
|
</el-form-item>
|
||||||
<!-- </el-option>-->
|
|
||||||
<!-- <el-option label="启用" value="1">-->
|
|
||||||
<!-- </el-option>-->
|
|
||||||
<!-- </el-select>-->
|
|
||||||
<!-- </el-form-item>-->
|
|
||||||
<el-form-item label="昵称" prop="nickname">
|
<el-form-item label="昵称" prop="nickname">
|
||||||
<el-input v-model.trim="queryParams.nickname" placeholder="请输入昵称" clearable size="small" />
|
<el-input v-model.trim="queryParams.nickname" placeholder="请输入昵称" clearable size="small" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
@ -43,25 +38,45 @@
|
|||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-form>
|
</el-form>
|
||||||
|
|
||||||
<el-table v-loading="loading" :data="umsMemberList" border>
|
<el-table v-loading="loading" :data="umsMemberList" border empty-text="暂无数据">
|
||||||
|
<el-table-column label="会员ID" prop="id" width="180" />
|
||||||
<el-table-column label="昵称" prop="nickname" width="150" />
|
<el-table-column label="昵称" prop="nickname" width="150" />
|
||||||
<el-table-column label="手机号码" prop="phoneHidden" width="150" />
|
<el-table-column label="手机号" prop="phoneHidden" width="150" />
|
||||||
<!-- <el-table-column label="佣金" width="120">
|
<!-- <el-table-column label="钱包" prop="phoneHidden" width="150" />
|
||||||
|
<el-table-column label="营收" prop="phoneHidden" width="150" />
|
||||||
|
<el-table-column label="积分" prop="integral" width="150" />
|
||||||
|
<el-table-column label="实名认证信息" prop="userName" width="150" />
|
||||||
|
<el-table-column label="银行卡信息" prop="phoneHidden" width="150" />-->
|
||||||
|
<el-table-column label="账号状态" prop="status" width="150">
|
||||||
<template v-slot="scope">
|
<template v-slot="scope">
|
||||||
<div>0.00</div>
|
<el-switch
|
||||||
|
:model-value="scope.row.status"
|
||||||
|
:active-value="1"
|
||||||
|
:inactive-value="0"
|
||||||
|
active-text="启用"
|
||||||
|
inactive-text="禁用"
|
||||||
|
inline-prompt
|
||||||
|
:before-change="
|
||||||
|
() => {
|
||||||
|
return handleChangeUserStatus(scope.row);
|
||||||
|
}
|
||||||
|
"
|
||||||
|
>
|
||||||
|
</el-switch>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="积分" width="120">
|
<el-table-column label="内部账号" prop="userId" width="90">
|
||||||
<template v-slot="scope">
|
<template v-slot="scope">
|
||||||
<div>0.00</div>
|
{{ scope.row.userId ? '内部账号' : '外部账号' }}
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="余额" width="120">
|
<el-table-column label="关注数量" prop="followCount" width="100" />
|
||||||
<template v-slot="scope">
|
<el-table-column label="粉丝数量" prop="fansCount" width="100" />
|
||||||
<div>0.00</div>
|
<el-table-column label="好友数量" prop="friendsCount" width="100" />
|
||||||
</template>
|
<el-table-column label="推广码" prop="spreadUid" width="150" />
|
||||||
</el-table-column>-->
|
<el-table-column label="推广人" prop="spreadUid" width="150" />
|
||||||
<el-table-column label="注册时间" prop="createTime" width="180">
|
<el-table-column label="openId" prop="openId" width="150" />
|
||||||
|
<!-- <el-table-column label="注册时间" prop="createTime" width="180">
|
||||||
<template v-slot="scope">
|
<template v-slot="scope">
|
||||||
<div>{{ parseTime(scope.row.createTime) }}</div>
|
<div>{{ parseTime(scope.row.createTime) }}</div>
|
||||||
</template>
|
</template>
|
||||||
@ -70,24 +85,113 @@
|
|||||||
<template v-slot="scope">
|
<template v-slot="scope">
|
||||||
<div>{{ parseTime(scope.row.createTime) }}</div>
|
<div>{{ parseTime(scope.row.createTime) }}</div>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>-->
|
||||||
<el-table-column label="备注">
|
<el-table-column label="备注">
|
||||||
<template v-slot="scope">
|
<template v-slot="scope">
|
||||||
<span class="mr10">{{ scope.row.mark }}</span>
|
<span class="mr10">{{ scope.row.mark }}</span>
|
||||||
<i class="el-icon-edit pointer" @click="showUpdateMark(scope.row)"></i>
|
<i class="el-icon-edit pointer" @click="showUpdateMark(scope.row)"></i>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="操作" class-name="small-padding fixed-width" fix="right" width="200">
|
<el-table-column label="操作" class-name="small-padding fixed-width" fixed="right" width="200">
|
||||||
<template v-slot="scope">
|
<template v-slot="scope">
|
||||||
<el-button size="small" type="text" @click="showStatistics(scope.row.id)" v-hasPermi="['ums:member:statistics']">查看数据 </el-button>
|
<el-button size="small" type="text" @click="showUserAccountModal(scope.row)">账户数据 </el-button>
|
||||||
|
<el-button size="small" type="text">充值消费记录 </el-button>
|
||||||
|
<el-button size="small" type="text">开通代理 </el-button>
|
||||||
|
<el-button size="small" type="text" @click="showUserAccountEditModal(scope.row)">编辑 </el-button>
|
||||||
|
<el-button size="small" type="text">余额变更记录 </el-button>
|
||||||
|
<el-button size="small" type="text">开通易生支付 </el-button>
|
||||||
|
<el-button size="small" type="text" @click="showUserLoginInfoModal(scope.row, true)">登录记录 </el-button>
|
||||||
|
<el-button size="small" type="text">操作日志 </el-button>
|
||||||
|
<el-button size="small" type="text">封禁记录 </el-button>
|
||||||
|
<!-- <el-button size="small" type="text" @click="showStatistics(scope.row.id)" v-hasPermi="['ums:member:statistics']">查看数据 </el-button>
|
||||||
<el-button size="small" type="text" @click="goOrder(scope.row.phoneEncrypted)">查看下单</el-button>
|
<el-button size="small" type="text" @click="goOrder(scope.row.phoneEncrypted)">查看下单</el-button>
|
||||||
<el-button size="small" type="text" @click="goCart(scope.row.phoneEncrypted)">查看购物车</el-button>
|
<el-button size="small" type="text" @click="goCart(scope.row.phoneEncrypted)">查看购物车</el-button>-->
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
</el-table>
|
</el-table>
|
||||||
<pagination :total="total" v-model:page="queryParams.current" v-model:limit="queryParams.size" @pagination="getList" />
|
<pagination :total="total" v-model:page="queryParams.current" v-model:limit="queryParams.size" @pagination="getList" />
|
||||||
</div>
|
</div>
|
||||||
<!-- <SeeAdsComponent ref="seeAdsComponentRef" v-if="!show" @confirmOk="confirmOk" />-->
|
<!-- 会员账户详情-->
|
||||||
|
<el-dialog :title="userAccountModal.title" v-model="userAccountModal.open" width="500px" append-to-body>
|
||||||
|
<el-descriptions direction="vertical" :column="3" border>
|
||||||
|
<el-descriptions-item label="钱包">¥{{ userAccountModal.data.wallet || 0 }}</el-descriptions-item>
|
||||||
|
<el-descriptions-item label="营收">¥{{ userAccountModal.data.revenue || 0 }}</el-descriptions-item>
|
||||||
|
<el-descriptions-item label="积分余额">¥{{ userAccountModal.data.integralBalance || 0 }}</el-descriptions-item>
|
||||||
|
<el-descriptions-item label="账户余额">¥{{ userAccountModal.data.moneyBalance || 0 }}</el-descriptions-item>
|
||||||
|
<el-descriptions-item label="历史总积分">¥{{ userAccountModal.data.totalIntegralBalance || 0 }}</el-descriptions-item>
|
||||||
|
</el-descriptions>
|
||||||
|
</el-dialog>
|
||||||
|
<!--会员登录信息-->
|
||||||
|
<el-dialog title="会员登录信息" v-model="userLoginInfoModalVisible" width="800px" append-to-body>
|
||||||
|
<el-table v-loading="userLoginInfoTableLoading" :data="userLoginInfo.data" border empty-text="暂无数据">
|
||||||
|
<el-table-column label="手机号" prop="phone" width="150" />
|
||||||
|
<el-table-column label="IP" prop="ipaddr" width="150"></el-table-column>
|
||||||
|
<el-table-column label="登陆地点" prop="loginLocation" width="180" />
|
||||||
|
<el-table-column label="浏览器类型" prop="browser" />
|
||||||
|
<el-table-column label="操作系统" prop="os" width="100" />
|
||||||
|
<el-table-column label="登录时间" prop="loginTime" width="100" />
|
||||||
|
</el-table>
|
||||||
|
<pagination
|
||||||
|
v-if="userLoginInfo.total"
|
||||||
|
:total="userLoginInfo.total"
|
||||||
|
v-model:page="loginDataParams.current"
|
||||||
|
v-model:limit="loginDataParams.size"
|
||||||
|
@pagination="showUserLoginInfoModal"
|
||||||
|
/>
|
||||||
|
</el-dialog>
|
||||||
|
<!--编辑会员基础信息-->
|
||||||
|
<el-dialog title="编辑会员信息" v-model="userAccountEditModal.open" width="500px" append-to-body>
|
||||||
|
<el-form label-width="auto" :rules="userEditRules" :model="userAccountEditModal.data" ref="editForm" size="default">
|
||||||
|
<el-form-item label="昵称" prop="nickname">
|
||||||
|
<el-input v-model.trim="userAccountEditModal.data.nickname" placeholder="请输入会员昵称" size="small" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="密码" prop="password">
|
||||||
|
<el-input v-model.trim="userAccountEditModal.data.password" placeholder="请输入会员密码" size="small" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="手机号" prop="phone">
|
||||||
|
<el-input v-model.trim="userAccountEditModal.data.phone" placeholder="请输入会员手机号" size="small" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="备注" prop="mark">
|
||||||
|
<el-input v-model.trim="userAccountEditModal.data.mark" placeholder="请输入备注" size="small" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="状态" prop="status">
|
||||||
|
<el-switch
|
||||||
|
:active-value="1"
|
||||||
|
:inactive-value="0"
|
||||||
|
active-text="启用"
|
||||||
|
inactive-text="禁用"
|
||||||
|
inline-prompt
|
||||||
|
v-model="userAccountEditModal.data.status"
|
||||||
|
/>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="头像" prop="avatar">
|
||||||
|
<!-- 暂时先用输入框组件,后续OSS上传功能好了迁移到上传upload组件-->
|
||||||
|
<el-input v-model.trim="userAccountEditModal.data.avatar" placeholder="请输入头像" size="small" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="性别" prop="gender">
|
||||||
|
<DictRadio v-model="userAccountEditModal.data.gender" radioData="sys_user_sex" size="small" :show-all="'all'" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="地址" prop="address">
|
||||||
|
<AddressSelector v-model="userAccountEditModal.data.fullArea" style="width: 100%" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="生日" prop="birthday">
|
||||||
|
<el-input v-model.trim="userAccountEditModal.data.birthday" placeholder="请选择生日" size="small" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="用户等级" prop="level">
|
||||||
|
<el-input v-model.trim="userAccountEditModal.data.level" placeholder="请输入用户等级" size="small" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="剩余积分" prop="integral">
|
||||||
|
<el-input v-model.trim="userAccountEditModal.data.integral" placeholder="请输入剩余积分" size="small" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-row>
|
||||||
|
<el-col :span="12"> </el-col>
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-button type="danger" @click="closeEditUser">关闭</el-button>
|
||||||
|
<el-button type="primary" @click="submitEditUser">保存</el-button>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
</el-form>
|
||||||
|
</el-dialog>
|
||||||
<!-- 统计 -->
|
<!-- 统计 -->
|
||||||
<el-dialog :title="statisticsObj.title" v-model="statisticsObj.open" width="500px" append-to-body>
|
<el-dialog :title="statisticsObj.title" v-model="statisticsObj.open" width="500px" append-to-body>
|
||||||
<el-descriptions direction="vertical" :column="2" border>
|
<el-descriptions direction="vertical" :column="2" border>
|
||||||
@ -120,16 +224,19 @@ import {
|
|||||||
listUmsMember,
|
listUmsMember,
|
||||||
updateUmsMember,
|
updateUmsMember,
|
||||||
updateUmsMemberMark,
|
updateUmsMemberMark,
|
||||||
viewStatistics
|
getUserAccountInfo,
|
||||||
|
upDateMemberStatus,
|
||||||
|
getUserLoginInfoData,
|
||||||
|
editUserData
|
||||||
} from '@/api/ums/member';
|
} from '@/api/ums/member';
|
||||||
import dateUtil from '@/utils/DateUtil';
|
import dateUtil from '@/utils/DateUtil';
|
||||||
import { isStarRepo } from '@/utils/is-star-plugin';
|
|
||||||
import { useUserStore } from '@/store/modules/user';
|
import { useUserStore } from '@/store/modules/user';
|
||||||
// import SeeAdsComponent from '@/components/SeeAdsComponent.vue';
|
import AddressSelector from '@/views/components/AddressSelector/index.vue';
|
||||||
|
import { addOmsOrder, updateOmsOrder } from '@/api/oms/order.js';
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'UmsMember',
|
name: 'UmsMember',
|
||||||
// components: { SeeAdsComponent },
|
components: { AddressSelector },
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
show: false,
|
show: false,
|
||||||
@ -170,6 +277,11 @@ export default {
|
|||||||
status: undefined,
|
status: undefined,
|
||||||
hasMark: undefined
|
hasMark: undefined
|
||||||
},
|
},
|
||||||
|
// 登录信息分页查询参数
|
||||||
|
loginDataParams: {
|
||||||
|
current: 1,
|
||||||
|
size: 10
|
||||||
|
},
|
||||||
dateRange: [],
|
dateRange: [],
|
||||||
// 表单参数
|
// 表单参数
|
||||||
form: {},
|
form: {},
|
||||||
@ -188,13 +300,46 @@ export default {
|
|||||||
aftersaleCount: 0
|
aftersaleCount: 0
|
||||||
},
|
},
|
||||||
title: '用户数据统计'
|
title: '用户数据统计'
|
||||||
}
|
},
|
||||||
|
|
||||||
|
// 会员账户信息
|
||||||
|
userAccountModal: {
|
||||||
|
open: false,
|
||||||
|
data: {
|
||||||
|
wallet: 0,
|
||||||
|
revenue: 0,
|
||||||
|
integralBalance: 0.0,
|
||||||
|
moneyBalance: 0,
|
||||||
|
totalIntegralBalance: 0
|
||||||
|
},
|
||||||
|
title: '会员账户信息'
|
||||||
|
},
|
||||||
|
// 会员登录信息信息
|
||||||
|
userLoginInfo: {
|
||||||
|
total: 0,
|
||||||
|
data: []
|
||||||
|
},
|
||||||
|
userAccountEditModal: {
|
||||||
|
open: false,
|
||||||
|
data: {}
|
||||||
|
},
|
||||||
|
userEditRules: {
|
||||||
|
nickname: [{ required: true, message: '昵称不能为空', trigger: 'blur' }],
|
||||||
|
/*password: [{ required: true, message: '密码不能为空', trigger: 'blur' }],*/
|
||||||
|
/* address: [{ required: true, message: '地址不能为空', trigger: 'change' }],*/
|
||||||
|
/* avatar: [{ required: true, message: '头像不能为空', trigger: 'change' }],*/
|
||||||
|
/* gendor: [{ required: true, message: '性别不能为空', trigger: 'change' }],*/
|
||||||
|
birthday: [{ required: true, message: '生日不能为空', trigger: 'change' }],
|
||||||
|
level: [{ required: true, message: '用户等级不能为空', trigger: 'blur' }],
|
||||||
|
integral: [{ required: true, message: '积分不能为空', trigger: 'blur' }],
|
||||||
|
/* email: [{ type: 'email', message: '请输入正确的邮箱地址', trigger: ['blur', 'change'] }],*/
|
||||||
|
phone: [{ required: true, pattern: /^1[3|4|5|6|7|8|9][0-9]\d{8}$/, message: '请输入正确的手机号码', trigger: 'blur' }]
|
||||||
|
},
|
||||||
|
userLoginInfoModalVisible: false,
|
||||||
|
userLoginInfoTableLoading: false
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
/* this.$nextTick(() => {
|
|
||||||
this.$refs.seeAdsComponentRef.show();
|
|
||||||
});*/
|
|
||||||
this.show = true;
|
this.show = true;
|
||||||
this.getList();
|
this.getList();
|
||||||
},
|
},
|
||||||
@ -206,41 +351,6 @@ export default {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
/* async confirmOk(success) {
|
|
||||||
if (success) {
|
|
||||||
const res = await isStarRepo(
|
|
||||||
'zccbbg',
|
|
||||||
'RuoYi-Mall',
|
|
||||||
this.userId,
|
|
||||||
'https://mall.ichengle.top/member/member',
|
|
||||||
'ruoyi-mall-商城',
|
|
||||||
'https://gitee.com/zccbbg/RuoYi-Mall'
|
|
||||||
);
|
|
||||||
this.show = res;
|
|
||||||
if (res) {
|
|
||||||
this.getList();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},*/
|
|
||||||
showUpdateMark(record) {
|
|
||||||
this.remarkModal = {
|
|
||||||
visible: true,
|
|
||||||
mark: record.mark,
|
|
||||||
memberId: record.id
|
|
||||||
};
|
|
||||||
},
|
|
||||||
updateRemark() {
|
|
||||||
updateUmsMemberMark({ id: this.remarkModal.memberId, mark: this.remarkModal.mark }).then((res) => {
|
|
||||||
if (res > 0) {
|
|
||||||
this.$message.success('修改成功');
|
|
||||||
this.remarkModal.visible = false;
|
|
||||||
const obj = this.umsMemberList.filter((it) => it.id === this.remarkModal.memberId)[0];
|
|
||||||
obj.mark = this.remarkModal.mark;
|
|
||||||
} else {
|
|
||||||
this.$message.success('修改失败');
|
|
||||||
}
|
|
||||||
});
|
|
||||||
},
|
|
||||||
/** 查询会员信息列表 */
|
/** 查询会员信息列表 */
|
||||||
getList() {
|
getList() {
|
||||||
this.loading = true;
|
this.loading = true;
|
||||||
@ -417,6 +527,115 @@ export default {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
// 展示会员账号详情弹框
|
||||||
|
showUserAccountModal(record) {
|
||||||
|
getUserAccountInfo(record.id).then((response) => {
|
||||||
|
this.userAccountModal = {
|
||||||
|
open: true,
|
||||||
|
data: response.data || {}
|
||||||
|
};
|
||||||
|
});
|
||||||
|
},
|
||||||
|
|
||||||
|
// 编辑会员账号详情弹框
|
||||||
|
showUserAccountEditModal(record) {
|
||||||
|
this.userAccountEditModal = {
|
||||||
|
data: { ...record, gender: String(record.gender) } || {},
|
||||||
|
open: true
|
||||||
|
};
|
||||||
|
},
|
||||||
|
submitEditUser() {
|
||||||
|
this.$refs['editForm'].validate((valid) => {
|
||||||
|
if (valid) {
|
||||||
|
const { fullArea } = this.userAccountEditModal.data || {};
|
||||||
|
const params = {
|
||||||
|
...this.userAccountEditModal.data
|
||||||
|
};
|
||||||
|
if (fullArea && fullArea.length) {
|
||||||
|
const [province = '', city = '', district = ''] = fullArea;
|
||||||
|
params.province = province;
|
||||||
|
params.city = city;
|
||||||
|
params.district = district;
|
||||||
|
}
|
||||||
|
editUserData(params).then((response) => {
|
||||||
|
this.$modal.msgSuccess('修改成功');
|
||||||
|
this.closeEditUser();
|
||||||
|
this.getList();
|
||||||
|
});
|
||||||
|
}
|
||||||
|
});
|
||||||
|
},
|
||||||
|
closeEditUser() {
|
||||||
|
this.userAccountEditModal = {
|
||||||
|
open: false,
|
||||||
|
data: {}
|
||||||
|
};
|
||||||
|
},
|
||||||
|
// 展示登录详情弹框
|
||||||
|
showUserLoginInfoModal(record, isFirst) {
|
||||||
|
const { id } = this.userLoginInfo.record || {};
|
||||||
|
const reqParams = {
|
||||||
|
...this.loginDataParams,
|
||||||
|
memberId: record.id ? record.id : id
|
||||||
|
};
|
||||||
|
this.userLoginInfoTableLoading = true;
|
||||||
|
getUserLoginInfoData(reqParams)
|
||||||
|
.then((response) => {
|
||||||
|
const { records = [], total = 0 } = response.data || {};
|
||||||
|
if (isFirst) {
|
||||||
|
this.userLoginInfoModalVisible = true;
|
||||||
|
}
|
||||||
|
this.userLoginInfo = {
|
||||||
|
total: total,
|
||||||
|
data: records || [],
|
||||||
|
record: record
|
||||||
|
};
|
||||||
|
this.userLoginInfoTableLoading = false;
|
||||||
|
})
|
||||||
|
.catch(() => {
|
||||||
|
this.userLoginInfoTableLoading = false;
|
||||||
|
});
|
||||||
|
},
|
||||||
|
|
||||||
|
showUpdateMark(record) {
|
||||||
|
this.remarkModal = {
|
||||||
|
visible: true,
|
||||||
|
mark: record.mark,
|
||||||
|
memberId: record.id
|
||||||
|
};
|
||||||
|
},
|
||||||
|
updateRemark() {
|
||||||
|
updateUmsMemberMark({ id: this.remarkModal.memberId, mark: this.remarkModal.mark }).then((res) => {
|
||||||
|
if (res > 0) {
|
||||||
|
this.$modal.msgSuccess('修改成功');
|
||||||
|
this.remarkModal.visible = false;
|
||||||
|
const obj = this.umsMemberList.filter((it) => it.id === this.remarkModal.memberId)[0];
|
||||||
|
obj.mark = this.remarkModal.mark;
|
||||||
|
} else {
|
||||||
|
this.$modal.msgSuccess('修改失败');
|
||||||
|
}
|
||||||
|
});
|
||||||
|
},
|
||||||
|
|
||||||
|
handleChangeUserStatus(row) {
|
||||||
|
const text = row.status == '1' ? '禁用' : '启用';
|
||||||
|
return this.$modal
|
||||||
|
.confirm(`是否确认${text}的用户?`)
|
||||||
|
.then(() => {
|
||||||
|
upDateMemberStatus({ id: row.id, status: row.status == '1' ? 0 : 1 })
|
||||||
|
.then(() => {
|
||||||
|
this.getList();
|
||||||
|
this.$modal.msgSuccess('会员状态修改成功');
|
||||||
|
})
|
||||||
|
.catch(() => {
|
||||||
|
this.$modal.msgError('会员状态修改失败');
|
||||||
|
});
|
||||||
|
return true;
|
||||||
|
})
|
||||||
|
.catch(() => {
|
||||||
|
return false;
|
||||||
|
});
|
||||||
|
},
|
||||||
showStatistics(memberId) {
|
showStatistics(memberId) {
|
||||||
this.$router.push({
|
this.$router.push({
|
||||||
path: '/videoManage/detail',
|
path: '/videoManage/detail',
|
||||||
@ -424,11 +643,6 @@ export default {
|
|||||||
memberId: memberId
|
memberId: memberId
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
// viewStatistics(memberId).then((response) => {
|
|
||||||
// this.statisticsObj.data = response;
|
|
||||||
// this.statisticsObj.open = true;
|
|
||||||
// });
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -24,9 +24,9 @@ export default defineConfig(({ mode, command }) => {
|
|||||||
open: true,
|
open: true,
|
||||||
proxy: {
|
proxy: {
|
||||||
[env.VITE_APP_BASE_API]: {
|
[env.VITE_APP_BASE_API]: {
|
||||||
// target: 'http://192.168.1.13:8080',
|
target: 'http://192.168.1.13:8080',
|
||||||
// target: 'http://192.168.1.250:8080',
|
// target: 'http://192.168.1.250:8080',
|
||||||
target: 'http://111.62.22.190:8080', // 测试环境
|
// target: 'http://111.62.22.190:8080', // 测试环境
|
||||||
changeOrigin: true,
|
changeOrigin: true,
|
||||||
ws: true,
|
ws: true,
|
||||||
rewrite: (path) => path.replace(new RegExp('^' + env.VITE_APP_BASE_API), ''),
|
rewrite: (path) => path.replace(new RegExp('^' + env.VITE_APP_BASE_API), ''),
|
||||||
|
Loading…
x
Reference in New Issue
Block a user