12 changed files with 602 additions and 1082 deletions
-
1.env.development
-
5.env.test
-
55src/views/audit/rechargeAudit.vue
-
8src/views/audit/refundAudit.vue
-
212src/views/consume/coinConsumeDetail.vue
-
159src/views/home.vue
-
324src/views/index.vue
-
38src/views/refund/coinRefundDetail.vue
-
143src/views/usergold/clientCountBalance.vue
-
193src/views/usergold/clientCountDetail.vue
-
42src/views/workspace/index.vue
-
2stats.html
@ -1,6 +1,5 @@ |
|||
VITE_API_BASE='http://192.168.8.220:8081/' |
|||
# VITE_API_BASE='https://hwjb.homilychart.com/gold_htms_dev' |
|||
# VITE_API_BASE='http://54.251.137.151:10704/' |
|||
# VITE_API_BASE='http://192.168.9.28:8081/' |
|||
# VITE_API_BASE='http://18.143.76.3:10704/' |
|||
|
@ -1,6 +1,5 @@ |
|||
# VITE_API_BASE='https://hwjb.homilychart.com/gold_htms_prod' |
|||
#VITE_API_BASE='http://54.251.137.151:10704/' |
|||
VITE_API_BASE='http://192.168.8.94:8080/' |
|||
VITE_API_BASE='http://192.168.8.220:8081/' |
|||
#VITE_API_BASE='https://hwjb.homilychart.com/gold_htms_dev' |
|||
# VITE_API_BASE='http://192.168.8.225:8080/' |
|||
|
|||
# VITE_API_BASE='http://18.143.76.3:10704/' |
@ -1,296 +1,44 @@ |
|||
<script setup> |
|||
// 导航栏在这 |
|||
import { ref, onMounted, reactive, computed, watch } from 'vue' |
|||
import { useRouter } from 'vue-router' |
|||
import ElementPlus from 'element-plus' |
|||
import { VscGlobe } from 'vue-icons-plus/vsc' |
|||
import { ElMessage, ElMessageBox } from 'element-plus' |
|||
import axios from 'axios' |
|||
import API from '@/util/http' |
|||
import dmmn from '../assets/blue.png' |
|||
import { useRoute } from 'vue-router' |
|||
|
|||
const router = useRouter() |
|||
const imgrule1 = dmmn |
|||
const messageVisible = ref(false) |
|||
|
|||
// 这是获取用户信息的接口 |
|||
const adminData = ref({ |
|||
name: '' |
|||
}) |
|||
|
|||
const getAdminData = async function () { |
|||
try { |
|||
const result = await API({ url: '/admin/userinfo', data: {} }) |
|||
adminData.value = result |
|||
console.log('请求成功', result) |
|||
console.log('用户信息', adminData.value) |
|||
} catch (error) { |
|||
console.log('请求失败', error) |
|||
} |
|||
} |
|||
// 获取地区 |
|||
const areas = ref([]) |
|||
// 直接在组件内维护当前地区状态,不太懂,包老师写的 |
|||
const currentArea = ref('全部') |
|||
|
|||
const getAreas = async function () { |
|||
try { |
|||
const result = await API({ url: '/general/market', data: {} }) |
|||
areas.value = result.data |
|||
console.log('请求成功', result) |
|||
} catch (error) { |
|||
console.log('请求失败', error) |
|||
} |
|||
} |
|||
// 查看个人信息弹出框 |
|||
const openMessage = function () { |
|||
messageVisible.value = true |
|||
} |
|||
const closeMessage = function () { |
|||
messageVisible.value = false |
|||
} |
|||
const message = function () { |
|||
openMessage() |
|||
} |
|||
|
|||
// 获取machineId |
|||
|
|||
// function logout() { |
|||
// const machineId = localStorage.getItem('machineId') |
|||
// console.log('machineId:', machineId) |
|||
// localStorage.removeItem('token') |
|||
// // localStorage.clear(); |
|||
// router.push('/login?machineId=' + machineId) |
|||
// //添加刷新页面的代码 |
|||
// // window.location.reload(); |
|||
// ElMessage.success('退出成功') |
|||
// } |
|||
|
|||
// 挂载 |
|||
onMounted(async function () { |
|||
// 获取用户信息 |
|||
getAdminData() |
|||
// 获取地区 |
|||
getAreas() |
|||
}) |
|||
// 处理地区点击事件,直接在组件内更新当前地区,包老师改的,直接传参 |
|||
const changeDataByArea = (item) => { |
|||
currentArea.value = item |
|||
} |
|||
//官网折叠 |
|||
const isCollapse = ref(false) |
|||
const handleOpen = (key, keyPath) => { |
|||
console.log(key, keyPath) |
|||
} |
|||
const handleClose = (key, keyPath) => { |
|||
console.log(key, keyPath) |
|||
} |
|||
</script> |
|||
|
|||
<template> |
|||
<div class="common-layout"> |
|||
<el-container> |
|||
<el-aside style=" |
|||
width: 15%; |
|||
min-width: 180px; |
|||
position: fixed; /* 固定位置 */ |
|||
top: 0; |
|||
left: 0; |
|||
height: 100vh; /* 高度占满视口 */ |
|||
z-index: 100; /* 确保侧边栏在其他元素之上 */ |
|||
"> |
|||
<div class="logo"> |
|||
<img src="../assets/新logo.png" alt="logo" style="width: 80px; height: 80px" /> |
|||
<!-- <div style="font-size: 16px; font-weight: bold; color: black; text-align: center;" ><h1>海外金币管理系统</h1></div> --> |
|||
<!-- ... 已有代码 ... --> |
|||
|
|||
<el-row> |
|||
<el-col> |
|||
<el-card style="margin-top: 20px"> |
|||
<template #header> |
|||
<div class="card-header"> |
|||
<div class="card-title">导出列表</div> |
|||
</div> |
|||
<el-card style="min-height: 90%;"> |
|||
<el-radio-group v-model="isCollapse" style="margin-bottom: 20px"> |
|||
<el-radio-button :value="false">扩展</el-radio-button> |
|||
<el-radio-button :value="true">收缩</el-radio-button> |
|||
</el-radio-group> |
|||
|
|||
<el-menu :router="true" class="el-menu-vertical-demo" :collapse="isCollapse" @open="handleOpen" @close="handleClose"> |
|||
<el-menu-item |
|||
index="/workspace" |
|||
v-if=" |
|||
adminData.permission == 1 || |
|||
adminData.permission == 2 || |
|||
adminData.permission == 3 || |
|||
adminData.permission == 5 |
|||
"> |
|||
<el-icon><Folder /></el-icon> |
|||
<span>工作台</span> |
|||
</el-menu-item> |
|||
|
|||
<el-sub-menu index="2" v-if=" |
|||
adminData.permission == 1 || |
|||
adminData.permission == 3 || |
|||
adminData.permission == 5 |
|||
"> |
|||
<template #title> |
|||
<el-icon><Folder /></el-icon> |
|||
<span>财务审核</span> |
|||
</template> |
|||
<el-menu-item index="/rechargeAudit">充值审核</el-menu-item> |
|||
<el-menu-item index="/refundAudit">退款审核</el-menu-item> |
|||
</el-sub-menu> |
|||
|
|||
<el-menu-item |
|||
index="/rate" |
|||
v-if=" |
|||
adminData.permission == 1 || |
|||
adminData.permission == 2 || |
|||
adminData.permission == 3 || |
|||
adminData.permission == 5 |
|||
"> |
|||
<el-icon><Folder /></el-icon> |
|||
<span>汇率管理</span> |
|||
</el-menu-item> |
|||
|
|||
<el-sub-menu index="4" v-if=" |
|||
adminData.permission == 1 || |
|||
adminData.permission == 2 || |
|||
adminData.permission == 5 |
|||
"> |
|||
<template #title> |
|||
<el-icon><Folder /></el-icon> |
|||
<span>充值管理</span> |
|||
</template> |
|||
<el-menu-item index="/coinRecharge">金币充值</el-menu-item> |
|||
<el-menu-item index="/beanRecharge">金豆充值</el-menu-item> |
|||
</el-sub-menu> |
|||
|
|||
<el-sub-menu index="6" v-if=" |
|||
adminData.permission == 1 || |
|||
adminData.permission == 2 || |
|||
adminData.permission == 5 |
|||
"> |
|||
<template #title> |
|||
<el-icon> |
|||
<Folder /> |
|||
</el-icon> |
|||
<span>消耗管理</span> |
|||
<div style="height: 300px; overflow-y: auto"> |
|||
<el-table :data="exportList" style="width: 100%" :loading="isExportListLoading"> |
|||
<el-table-column prop="fileName" label="文件名" width="200" /> |
|||
<el-table-column prop="createTime" label="导出时间" width="200"> |
|||
<template #default="scope"> |
|||
{{ moment(scope.row.createTime).format('YYYY-MM-DD HH:mm:ss') }} |
|||
</template> |
|||
<el-menu-item index="/coinConsume">金币消耗</el-menu-item> |
|||
<el-menu-item index="/beanConsume">金豆消耗</el-menu-item> |
|||
</el-sub-menu> |
|||
|
|||
<el-sub-menu index="8" v-if=" |
|||
adminData.permission == 1 || |
|||
adminData.permission == 2 || |
|||
adminData.permission == 5 |
|||
"> |
|||
<template #title> |
|||
<el-icon> |
|||
<Folder /> |
|||
</el-icon> |
|||
<span>退款管理</span> |
|||
</el-table-column> |
|||
<el-table-column prop="status" label="状态" width="100"> |
|||
<template #default="scope"> |
|||
<span v-if="scope.row.status === 'processing'">处理中</span> |
|||
<span v-if="scope.row.status === 'completed'">已完成</span> |
|||
</template> |
|||
<el-menu-item index="/coinRefund">金币退款</el-menu-item> |
|||
<el-menu-item index="/beanRefund">金豆退款</el-menu-item> |
|||
</el-sub-menu> |
|||
<el-menu-item index="/usergold" v-if=" |
|||
adminData.permission == 1 || |
|||
adminData.permission == 2 || |
|||
adminData.permission == 3 || |
|||
adminData.permission == 5 |
|||
"> |
|||
<el-icon><Folder /></el-icon> |
|||
<span>客户账户明细</span> |
|||
</el-menu-item> |
|||
|
|||
<el-menu-item index="/permissions" v-if="adminData.permission == 1"> |
|||
<el-icon><Folder /></el-icon> |
|||
<span>权限管理</span> |
|||
</el-menu-item> |
|||
</el-menu> |
|||
</el-card> |
|||
</el-aside> |
|||
<el-container style="margin-left: 15%; min-width: 180px"> |
|||
<!-- 修改 el-header 样式 --> |
|||
<el-header style=" |
|||
position: fixed; |
|||
top: 0; |
|||
left: 15%; |
|||
right: 0; |
|||
z-index: 80; |
|||
background: white; |
|||
"> |
|||
|
|||
<el-menu class="el-menu-demo" mode="horizontal" :ellipsis="false"> |
|||
<el-sub-menu index="1" class="admin"> |
|||
<template #title> |
|||
<el-image :src="imgrule1" alt="错误" style="width: 50px; height: 50px" /> |
|||
<span style="margin-left: 10px">{{ adminData.name }}</span> |
|||
</el-table-column> |
|||
<el-table-column label="操作" width="100"> |
|||
<template #default="scope"> |
|||
<el-button |
|||
size="small" |
|||
type="primary" |
|||
@click="downloadExportFile(scope.row)" |
|||
:disabled="scope.row.status !== 'completed'" |
|||
> |
|||
下载 |
|||
</el-button> |
|||
</template> |
|||
<el-menu-item @click="message()">查看个人信息</el-menu-item> |
|||
<el-menu-item index="1-2" @click="logout">退出登录</el-menu-item> |
|||
</el-sub-menu> |
|||
</el-menu> |
|||
</el-header> |
|||
<!-- 修改 el-main 样式 --> |
|||
<el-main style="margin-top: 60px"> |
|||
<!-- 60px 是 el-header 的大致高度,可根据实际情况调整 --> |
|||
<router-view></router-view> |
|||
</el-main> |
|||
</el-container> |
|||
</el-container> |
|||
</div> |
|||
<!-- 查看个人信息 --> |
|||
<el-dialog v-model="messageVisible" title="查看个人信息" width="500px"> |
|||
<el-form :model="adminData"> |
|||
<el-form-item label="用户姓名" label-width="100px" label-position="left"> |
|||
<span class="message-font">{{ adminData.name }}</span> |
|||
</el-form-item> |
|||
<el-form-item label="精网号" label-width="100px" label-position="left"> |
|||
<span class="message-font">{{ adminData.jwcode }}</span> |
|||
</el-form-item> |
|||
<el-form-item label="地区" label-width="100px" label-position="left"> |
|||
<span class="message-font">{{ adminData.area }}</span> |
|||
</el-form-item> |
|||
<el-form-item label="注册时间" label-width="100px" label-position="left"> |
|||
<span class="message-font">{{ adminData.createTime }}</span> |
|||
</el-form-item> |
|||
</el-form> |
|||
<template #footer> |
|||
<div class="dialog-footer"> |
|||
<el-button text @click="closeMessage()">关闭</el-button> |
|||
</el-table-column> |
|||
</el-table> |
|||
</div> |
|||
</el-card> |
|||
</el-col> |
|||
</el-row> |
|||
</template> |
|||
</el-dialog> |
|||
</template> |
|||
|
|||
<style scoped> |
|||
.message-font { |
|||
font-size: 16px; |
|||
font-weight: bold; |
|||
} |
|||
|
|||
.admin { |
|||
margin-left: auto; |
|||
} |
|||
|
|||
.el-aside { |
|||
min-height: 100vh; |
|||
width: 200px; |
|||
} |
|||
/* background-color: #BFD8D2; */ |
|||
.logo { |
|||
margin: 20px 0px 20px 20px; |
|||
display: flex; |
|||
} |
|||
|
|||
.el-menu-demo { |
|||
border: none; /* 去除边框 */ |
|||
padding: 0; /* 去除内边距 */ |
|||
float: right; |
|||
/* 将菜单向右浮动 */ |
|||
} |
|||
.el-menu-vertical-demo:not(.el-menu--collapse) { |
|||
width: 240px; |
|||
min-height: 400px; |
|||
border: none; /* 去除边框 */ |
|||
} |
|||
|
|||
</style> |
|||
<script></script> |
2
stats.html
File diff suppressed because it is too large
View File
File diff suppressed because it is too large
View File
Write
Preview
Loading…
Cancel
Save
Reference in new issue