完善对外演示页面

pull/1/head
qzp 1 year ago
parent b7e095c528
commit 93c6a684ff

@ -15,25 +15,25 @@ const whiteList = ['/login', '/register'];
router.beforeEach((to, from, next) => {
NProgress.start()
if (getToken()) {
to.meta.title && useSettingsStore().setTitle(to.meta.title)
/* has token*/
if (to.path === '/login') {
next({ path: '/' })
NProgress.done()
} else {
next()
}
} else {
// 没有token
if (whiteList.indexOf(to.path) !== -1) {
// 在免登录白名单,直接进入
next()
} else {
next(`/login?redirect=${to.fullPath}`) // 否则全部重定向到登录页
NProgress.done()
}
}
// if (getToken()) {
// to.meta.title && useSettingsStore().setTitle(to.meta.title)
// /* has token*/
// if (to.path === '/login') {
// next({ path: '/' })
// NProgress.done()
// } else {
// next()
// }
// } else {
// // 没有token
// if (whiteList.indexOf(to.path) !== -1) {
// // 在免登录白名单,直接进入
// next()
// } else {
// next(`/login?redirect=${to.fullPath}`) // 否则全部重定向到登录页
// NProgress.done()
// }
// }
next()
})

@ -270,7 +270,7 @@ export const dynamicRoutes = [
{
path: 'transaction',
hidden: true,
component: () => import('@/views/visual/transaction/transaction.vue'),
component: () => import('@/views/visual/components/transaction.vue'),
name: 'transaction',
meta: { title: '交易总览',activeMenu: '/visual/index' }
},
@ -278,7 +278,7 @@ export const dynamicRoutes = [
{
path: 'transaction-node',
hidden: true,
component: () => import('@/views/visual/transaction-node/transaction-node.vue'),
component: () => import('@/views/visual/components/transaction-node.vue'),
name: 'transaction-node',
meta: { title: '交易节点',activeMenu: '/visual/index' }
},
@ -286,7 +286,7 @@ export const dynamicRoutes = [
{
path: 'transaction-block',
hidden: true,
component: () => import('@/views/visual/transaction-block/transaction-block.vue'),
component: () => import('@/views/visual/components/transaction-block.vue'),
name: 'transaction-block',
meta: { title: '交易区块',activeMenu: '/visual/index' }
},
@ -294,7 +294,7 @@ export const dynamicRoutes = [
{
path: 'transaction-broadcast',
hidden: true,
component: () => import('@/views/visual/transaction-broadcast/transaction-broadcast.vue'),
component: () => import('@/views/visual/components/transaction-broadcast.vue'),
name: 'transaction-broadcast',
meta: { title: '交易广播',activeMenu: '/visual/index' }
},
@ -302,7 +302,7 @@ export const dynamicRoutes = [
{
path: 'merkle',
hidden: true,
component: () => import('@/views/visual/merkle/merkle.vue'),
component: () => import('@/views/visual/components/merkle.vue'),
name: 'merkle',
meta: { title: 'Merkle',activeMenu: '/visual/index' }
},

@ -14,7 +14,7 @@ axios.defaults.headers['Content-Type'] = 'application/json;charset=utf-8'
const service = axios.create({
// axios中请求配置有baseURL选项表示请求URL公共部分
// baseURL: import.meta.env.VITE_APP_BASE_API,
baseURL: 'http://192.168.2.15:8800/',
baseURL: 'http://118.31.7.2:8800/',
// 超时
timeout: 10000
})
@ -114,9 +114,9 @@ service.interceptors.response.use(res => {
message = "系统接口请求超时";
} else if (message.includes("Request failed with status code")) {
if(message.includes("code 401")){
useUserStore().fedLogOut().then(() => {
location.href = '/login';
})
// useUserStore().fedLogOut().then(() => {
// location.href = '/login';
// })
}else if(message.includes("code 400")){
// ElNotification.error({ title: error.response.data })
ElMessage({ message: error.response.data.msg, type: 'error' })

@ -102,6 +102,8 @@ getRedPacket()
v-model:limit="params.size"
@pagination="getRedPacket"
/>
<el-empty v-show="total===0" :image-size="150"></el-empty>
</div>
<!-- 购买数字商品 -->
<el-row>
@ -133,6 +135,7 @@ getRedPacket()
v-model:limit="params1.size"
@pagination="getDigital"
/>
<el-empty v-show="total1===0" :image-size="150"></el-empty>
</div>
<el-dialog
v-model="dialogVisible"
@ -224,7 +227,7 @@ getRedPacket()
}
}
.red_packet{
padding: 0px 20px;
padding: 0px 20px 20px 20px;
width: 100%;
// display: flex;
// justify-content: space-between;
@ -345,6 +348,14 @@ getRedPacket()
}
}
}
}
:deep(.el-empty){
border: 1px solid #1854a6;
.el-empty__description{
p{
color: #ffffff;
}
}
}
}
</style>

@ -0,0 +1,42 @@
<script setup>
</script>
<template>
<div class="app-study">
<div>
</div>
<!--<el-row>
<el-col :span="24">
<img src="../../assets/images/32.png" alt="" />
<span>操作记录和成绩</span>
</el-col>
</el-row> -->
</div>
</template>
<style lang='scss' scoped>
.app-study{
// padding: 20px;
height: 105vh;
// border: 1px solid #238AFF;
// border-radius: 5px;
div{
margin-top: -90px;
margin-left: -130px;
height: 995px;
background: url('../../../assets/images/Merkle根.png' ) no-repeat !important;
background-size: 102% 100% !important;
}
.el-col-24 {
height: 69px;
padding: 15px 13px;
display: flex;
align-items: center;
span {
padding-left: 15px;
font-weight: bold;
font-size: 14px;
color: #ffff;
}
}
}
</style>

@ -0,0 +1,42 @@
<script setup>
</script>
<template>
<div class="app-study">
<div>
</div>
<!--<el-row>
<el-col :span="24">
<img src="../../assets/images/32.png" alt="" />
<span>操作记录和成绩</span>
</el-col>
</el-row> -->
</div>
</template>
<style lang='scss' scoped>
.app-study{
// padding: 20px;
height: 105vh;
// border: 1px solid #238AFF;
// border-radius: 5px;
div{
margin-top: -90px;
margin-left: -130px;
height: 995px;
background: url('../../../assets/images/交易区块.png' ) no-repeat !important;
background-size: 102% 100% !important;
}
.el-col-24 {
height: 69px;
padding: 15px 13px;
display: flex;
align-items: center;
span {
padding-left: 15px;
font-weight: bold;
font-size: 14px;
color: #ffff;
}
}
}
</style>

@ -0,0 +1,42 @@
<script setup>
</script>
<template>
<div class="app-study">
<div>
</div>
<!--<el-row>
<el-col :span="24">
<img src="../../assets/images/32.png" alt="" />
<span>操作记录和成绩</span>
</el-col>
</el-row> -->
</div>
</template>
<style lang='scss' scoped>
.app-study{
// padding: 20px;
height: 105vh;
// border: 1px solid #238AFF;
// border-radius: 5px;
div{
margin-top: -90px;
margin-left: -130px;
height: 995px;
background: url('../../../assets/images/交易广播.png' ) no-repeat !important;
background-size: 102% 100% !important;
}
.el-col-24 {
height: 69px;
padding: 15px 13px;
display: flex;
align-items: center;
span {
padding-left: 15px;
font-weight: bold;
font-size: 14px;
color: #ffff;
}
}
}
</style>

@ -0,0 +1,42 @@
<script setup>
</script>
<template>
<div class="app-study">
<div>
</div>
<!--<el-row>
<el-col :span="24">
<img src="../../assets/images/32.png" alt="" />
<span>操作记录和成绩</span>
</el-col>
</el-row> -->
</div>
</template>
<style lang='scss' scoped>
.app-study{
// padding: 20px;
height: 106vh;
// border: 1px solid #238AFF;
// border-radius: 5px;
div{
margin-top: -90px;
margin-left: -130px;
height: 995px;
background: url('../../../assets/images/交易节点.png' ) no-repeat !important;
background-size: 102% 100% !important;
}
.el-col-24 {
height: 69px;
padding: 15px 13px;
display: flex;
align-items: center;
span {
padding-left: 15px;
font-weight: bold;
font-size: 14px;
color: #ffff;
}
}
}
</style>

@ -16,13 +16,15 @@
<style lang='scss' scoped>
.app-study{
// padding: 20px;
height: 130vh;
height: 105vh;
// border: 1px solid #238AFF;
// border-radius: 5px;
div{
height: 100%;
background: url('../../../assets/images/Merkle根.png' ) no-repeat !important;
background-size: 100% 100% !important;
margin-top: -90px;
margin-left: -130px;
height: 995px;
background: url('../../../assets/images/央行可视化监控中心.png' ) no-repeat !important;
background-size: 102% 100% !important;
}
.el-col-24 {
height: 69px;

@ -2,8 +2,10 @@
const { proxy } = getCurrentInstance();
import * as centralBank from '@/api/centralBank'
import transaction from './components/transaction.vue';
// import currencyPut from '../digital-currency/currency-put.vue';
// import currency from '../currency/currency.vue';
import transactionNode from './components/transaction-node.vue';
import transactionBlock from './components/transaction-block.vue';
import transactionBroadcast from './components/transaction-broadcast.vue';
import merkle from './components/merkle.vue';
import useUserStore from "@/store/modules/user";
const userStore = useUserStore();
//
@ -121,14 +123,18 @@ getTableData()
<template>
<div class="app-central">
<div class="central-bank-title">
<div @click.native="go(1)">信息验证</div>
<div @click.native="go(2)">数字货币申请</div>
<div @click.native="go(3)">数字货币投放</div>
<div @click.native="go(1)">交易总览</div>
<div @click.native="go(2)">交易节点</div>
<div @click.native="go(3)">交易区块</div>
<div @click.native="go(4)">交易广播</div>
<div @click.native="go(5)">Merkle</div>
</div>
<div class="central-ban-information">
<transaction v-show="isDeployed == 1"></transaction>
<!-- <currency v-show="isDeployed == 2"></currency>
<currencyPut v-show="isDeployed == 3"></currencyPut> -->
<transaction-node v-show="isDeployed == 2"></transaction-node>
<transactionBlock v-show="isDeployed == 3"></transactionBlock>
<transactionBroadcast v-show="isDeployed == 4"></transactionBroadcast>
<merkle v-show="isDeployed == 5"></merkle>
</div>
</div>
</template>
@ -144,7 +150,7 @@ getTableData()
width: 202px;
height: 52px;
color: #ffffff;
background: url("../../assets/images/btn01.png") no-repeat;
background: url("../../assets/images/btn07.png") no-repeat;
margin-right: 25px;
text-align: center;
line-height: 52px;
@ -158,14 +164,21 @@ getTableData()
}
}
div:nth-child(2) {
background: url("../../assets/images/btn02.png") no-repeat;
background: url("../../assets/images/btn08.png") no-repeat;
}
div:nth-child(3) {
background: url("../../assets/images/btn03.png") no-repeat;
background: url("../../assets/images/btn09.png") no-repeat;
}
div:nth-child(4) {
background: url("../../assets/images/btn10.png") no-repeat;
}
div:nth-child(5) {
background: url("../../assets/images/btn11.png") no-repeat;
}
}
.central-ban-information {
overflow: hidden;
width: 100%;
background: #0e2e68;
border: 1px solid #238aff;

Loading…
Cancel
Save