Commit 4c32ff8d authored by salitedfish's avatar salitedfish

添加国裕项目

parent 478a6b62
NODE_ENV = 'production'
VUE_APP_CURRENTMODE = 'gy_prod'
VUE_APP_VERSION = '0'
\ No newline at end of file
NODE_ENV = 'development'
VUE_APP_CURRENTMODE = 'gy_test'
VUE_APP_VERSION = '0'
\ No newline at end of file
NODE_ENV = 'production'
VUE_APP_CURRENTMODE = 'gy_test'
VUE_APP_VERSION = '0'
\ No newline at end of file
...@@ -4,6 +4,7 @@ ...@@ -4,6 +4,7 @@
"private": true, "private": true,
"scripts": { "scripts": {
"dev:sy": "vue-cli-service serve --mode sy_test", "dev:sy": "vue-cli-service serve --mode sy_test",
"dev:gy": "vue-cli-service serve --mode gy_test",
"dev:cs": "vue-cli-service serve --mode cs_test", "dev:cs": "vue-cli-service serve --mode cs_test",
"dev:best": "vue-cli-service serve --mode best_test", "dev:best": "vue-cli-service serve --mode best_test",
"dev:hd": "vue-cli-service serve --mode hd_test", "dev:hd": "vue-cli-service serve --mode hd_test",
...@@ -15,11 +16,13 @@ ...@@ -15,11 +16,13 @@
"dev:ydyjy": "vue-cli-service serve --mode ydyjy_test", "dev:ydyjy": "vue-cli-service serve --mode ydyjy_test",
"build:hd_prod": "vue-cli-service build --mode hd_prod_build", "build:hd_prod": "vue-cli-service build --mode hd_prod_build",
"build:sy_prod": "vue-cli-service build --mode sy_prod_build", "build:sy_prod": "vue-cli-service build --mode sy_prod_build",
"build:gy_prod": "vue-cli-service build --mode gy_prod_build",
"build:cs_prod": "vue-cli-service build --mode cs_prod_build", "build:cs_prod": "vue-cli-service build --mode cs_prod_build",
"build:best_prod": "vue-cli-service build --mode best_prod_build", "build:best_prod": "vue-cli-service build --mode best_prod_build",
"build:dl_prod": "vue-cli-service build --mode dl_prod_build", "build:dl_prod": "vue-cli-service build --mode dl_prod_build",
"build:hl_prod": "vue-cli-service build --mode hl_prod_build", "build:hl_prod": "vue-cli-service build --mode hl_prod_build",
"build:hl_test": "vue-cli-service build --mode hl_test_build", "build:hl_test": "vue-cli-service build --mode hl_test_build",
"build:gy_test": "vue-cli-service build --mode gy_test_build",
"build:boe_prod": "vue-cli-service build --mode boe_prod_build", "build:boe_prod": "vue-cli-service build --mode boe_prod_build",
"build:gs": "vue-cli-service build --mode gs_build", "build:gs": "vue-cli-service build --mode gs_build",
"build:gs_prod": "vue-cli-service build --mode gs_prod_build", "build:gs_prod": "vue-cli-service build --mode gs_prod_build",
......
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width,initial-scale=1.0">
<link rel="icon" href="./gy/favicon.ico">
<title>Gopha国裕链</title>
<link rel="stylesheet" href="//at.alicdn.com/t/font_1321935_49vw1tllkgn.css">
<script src="https://cdn.bootcss.com/tinymce/4.7.4/tinymce.min.js"></script>
</head>
<body>
<div id="app"></div>
</body>
<style>
</style>
<script>
</script>
</html>
\ No newline at end of file
<template> <template>
<div> <div>
<span class="sign-box-type" @click="$emit('change-email')">邮箱登录 ></span> <span class="sign-box-type" @click="$emit('change-email')">邮箱登录 ></span>
<h1>手机登录</h1> <h1>登录/注册</h1>
<div class="tip"> <div class="tip">
您还可以进行 您还可以进行
<span @click="changeLogin">{{loginMethod}}</span>&nbsp;登录 <span @click="changeLogin">{{loginMethod}}</span>&nbsp;登录
......
...@@ -208,6 +208,34 @@ const configModules = { ...@@ -208,6 +208,34 @@ const configModules = {
template: './public/ydyjy/index.html', template: './public/ydyjy/index.html',
filename: 'index.html' filename: 'index.html'
} }
} },
// 国遇>测试环境
"gy_test": {
CHAIN_BROWSER_URL_PREFIX: 'http://120.26.174.69:8972/',
INERFACE_URL_PREFIX: 'http://172.16.101.87:46789',
/**
* 网站入口配置
*/
INDEX: {
// page 的入口
entry: './src/entry/gy/main.ts',
// 模板来源
template: './public/gy/index.html',
// 在 dist/index.html 的输出
filename: 'index.html'
}
},
// 国遇>正式环境
"gy_prod": {
CHAIN_BROWSER_URL_PREFIX: 'https://cx.chain33.pro/',
INERFACE_URL_PREFIX: 'https://sy.chain33.pro/api',
// CHAIN_BROWSER_URL_PREFIX: 'http://172.16.101.87:8995/',
// INERFACE_URL_PREFIX: 'http://172.16.101.87:8994/',
INDEX: {
entry: './src/entry/gy/main.ts',
template: './public/gy/index.html',
filename: 'index.html'
}
},
}; };
exports.model = configModules[process.env.VUE_APP_CURRENTMODE] exports.model = configModules[process.env.VUE_APP_CURRENTMODE]
\ No newline at end of file
<template>
<div id="App">
<router-view />
</div>
</template>
<script>
export default {
name: "app",
};
</script>
<style>
html {
height: 100%;
}
#App {
height: 100%;
}
html,
input,
button {
font-family: "Helvetica Neue", Helvetica, "PingFang SC", "Hiragino Sans GB",
"Microsoft YaHei", "微软雅黑", Arial, sans-serif;
}
* {
margin: 0;
padding: 0;
}
a:hover,
a:visited,
a:active,
a:link {
color: inherit;
text-decoration: none;
}
body {
height: 100%;
margin: 0;
font-size: 14px;
}
input::-webkit-search-cancel-button {
display: none;
}
input::-ms-clear {
display: none;
}
</style>
import Vue from 'vue';
// 取本地
import App from './App.vue';
import router from './router';
// 取公用
import axiosPlugin from '@/plugins/axios-plugin';
import '@/plugins/element.js';
import store from '@/store';
import Gfilters from '@/utils/tool/filter';
import md5 from 'js-md5'
Vue.prototype.$md5 = md5
Vue.use(axiosPlugin);
Vue.config.productionTip = false;
Gfilters(Vue);
new Vue({
router,
store,
render: h => h(App),
}).$mount('#app');
import Vue from 'vue';
import Router from 'vue-router';
import { getLoginCode } from '@/plugins/storage';
Vue.use(Router);
let router = new Router({ // todo 移除旧页面
routes: [
// 宣传页
{
path: '/',
name: 'home',
component: () => import('./views/Home.vue'),
},
// 登录
{
path: '/signIn',
name: 'signIn',
component: () => import('./views/SignIn.vue'),
},
{
path: '/main',
component: () => import(/* webpackChunkName: "main" */ './views/Main.vue'),
children: [
{
path: '/categoryManage',
name: 'categoryManage',
component: () => import(/* webpackChunkName: "categoryManage" */ '@/components/category/Index.vue'),
},
// 个人中心
{
path: '/userCenter',
name: 'userCenter',
component: () => import(/* webpackChunkName: "userCenter" */ '@/views/userCenter/index.vue')
},
{
path: '/choosePackage',
name: 'choosePackage',
component: () => import(/* webpackChunkName: "companyVerify" */ '@/views/userCenter/choosePackage.vue')
},
{
path: '/initPassword',
name: 'initPassword',
component: () => import(/* webpackChunkName: "initPassword" */ '@/views/userCenter/SetPassword.vue'),
},
{
path: '/companyVerify',
name: 'companyVerify',
component: () => import(/* webpackChunkName: "companyVerify" */ '@/views/userCenter/CompanyVerify.vue')
},
{
path: '/editPassword',
name: 'editPassword',
component: () => import(/* webpackChunkName: "editPassword" */ '@/views/userCenter/EditPassword.vue'),
},
{
path: '/editPhone',
name: 'editPhone',
component: () => import(/* webpackChunkName: "editPhone" */ '@/views/userCenter/EditPhone.vue'),
},
{
path: '/personVerify',
name: 'personVerify',
component: () => import(/* webpackChunkName: "personVerify" */ '@/views/userCenter/PersonVerify.vue')
},
{
path: '/editTemplate',
name: 'editTemplate',
component: () => import(/* webpackChunkName: "editTemplate" */ '@/views/template/editTemplate.vue'),
}
]
}
],
});
router.beforeEach((to, from, next) => {
const urls = ['/', '/signIn'];
if (to.path === `/signIn` && getLoginCode()) {
if (to.query && to.query.type && to.query.type == '1') {
}
else {
}
next();
}
if (!urls.includes(to.path) && !getLoginCode()) {
return next({ path: "/signIn" });
}
else {
next();
}
})
export default router;
This diff is collapsed.
<template>
<div class="main">
<!-- 左侧导航 -->
<main-menu class="col_left" />
<div class="col_right">
<main-header />
<div class="main_wrapper">
<router-view />
</div>
</div>
</div>
</template>
<script lang="ts">
import { Component, Vue } from "vue-property-decorator";
import MainHeader from "./MainHeader.vue";
import MainMenu from "@/components/MainMenu/MainMenu.vue";
@Component({
components: {
MainMenu,
MainHeader,
},
})
export default class Main extends Vue {}
</script>
<style scoped>
.main {
display: flex;
height: 100%;
}
.col_left {
flex-shrink: 0;
}
.col_right {
flex: 1;
display: flex;
flex-direction: column;
overflow: hidden;
}
.main_wrapper {
flex: 1;
min-height: 0;
overflow-y: scroll;
background: white;
height: 100%;
}
</style>
<template>
<header class="main_header">
<img class="icon_logo" src="../images/SigIn/logo.png" alt="logo" />
<div class="user_wrapper">
<i class="iconfont iconShapecopy1"></i>
<span class="user-text">UID:{{ getid || "10086" }}</span>
<ul class="menu_box">
<li @click="go()">退出</li>
</ul>
<i class="iconxiangyousanjiao iconfont"></i>
</div>
</header>
</template>
<script lang="ts">
import { GO_URLS } from "@/config/URLS";
import { Component, Vue } from "vue-property-decorator";
@Component
export default class MainHeader extends Vue {
[x: string]: any;
get getid() {
return JSON.parse(String(sessionStorage.getItem("user"))).id;
}
public go() {
sessionStorage.removeItem("user");
this.$router.push("/");
}
// 获取用户基本信息
async getUserInfos() {
const res = await this.$ajax({
type: "get",
url:
GO_URLS.user +
`/` +
JSON.parse(String(sessionStorage.getItem("user"))).id,
});
if (res) {
this.$store.commit("setuserInfos", res.data);
}
}
public mounted() {
this.getUserInfos();
}
}
</script>
<style scoped lang='less'>
// 大盒子
.main_header {
z-index: 1; /* shadow覆盖底部 */
position: relative;
height: 50px;
padding-right: 35px;
background: rgba(255, 255, 255, 1);
box-shadow: 0px 2px 40px 0px rgba(65, 70, 76, 0.07);
}
.icon_logo {
margin-left: 27px;
margin-top: 12px;
height: 23px;
}
.user_wrapper {
margin-top: 12px;
float: right;
height: 100%;
color: #353535;
cursor: pointer;
.iconShapecopy1 {
vertical-align: middle;
margin-right: 6px;
font-size: 20px;
color: #d6d8e1;
}
.iconxiangyousanjiao {
color: #b4b4b4;
transform: rotate(90deg);
display: inline-block;
font-size: 12px;
margin-left: 14px;
}
}
.user_wrapper .menu_box {
display: none;
}
.user_wrapper:hover .menu_box {
display: block;
}
.user-icon {
/* todo ui切块错误 */
margin-right: 6px;
vertical-align: middle;
height: 20px;
}
.user-text {
vertical-align: middle;
color: #b4b4b4;
}
.menu_box {
position: absolute;
top: 100%;
right: 35px;
margin: 0;
padding: 0;
line-height: 41px; /* 非精确ui */
width: 107px; /* 109 - border */
list-style: none;
border: 1px solid #e7e7e7;
text-align: center;
color: #797d84;
background: #fff;
}
.menu_box li {
transition: 0.5s;
cursor: pointer;
background: white;
}
.menu_box li:hover {
background: #f5f5f5;
}
</style>
<template>
<div class="sign-in">
<div class="img"></div>
<div class="fixed">
<div class="background-left"></div>
<div class="sign-in-box">
<!-- 手机+密码登录模块 -->
<phone-login
v-if="showPlg"
@change-email="changeEmail"
@SetPassword="
showPlg = false;
showSpd = true;
"
></phone-login>
<!-- email登录模块 -->
<email-login
v-if="showEmail"
@phone-email="phoneEmail"
@SetPassword="
showEmail = false;
showSpd = true;
"
></email-login>
<!-- 设置密码模块 -->
<set-password v-if="showSpd" @showLogin="showLogin"></set-password>
</div>
</div>
</div>
</template>
<script>
import SetPassword from "@/components/signin/setPassword.vue";
import PhoneLogin from "@/components/signin/phoneLogin.vue";
import EmailLogin from "@/components/signin/emailLogin.vue";
export default {
data() {
return {
showSpd: false, //设置密码
showPlg: true, //手机登录
showEmail: false, // 邮箱登录
};
},
components: {
SetPassword,
PhoneLogin,
EmailLogin,
},
computed: {
getType: function () {
return this.$store.state.businessType;
},
},
methods: {
showLogin() {
this.showSpd = false;
if (this.getType === 0 || this.getType === 1) {
this.showPlg = true;
} else {
this.showEmail = true;
}
},
// 切换至email登录
changeEmail() {
this.showEmail = true;
this.showPlg = false;
},
// 切换至手机登录
phoneEmail() {
this.showEmail = false;
this.showPlg = true;
},
},
};
</script>
<style lang="less" scoped>
.sign-in {
position: relative;
background: #ececec;
}
.img {
position: absolute;
left: 26px;
top: 14px;
width: 200px;
height: 30px;
background: url("../images/SigIn/logo.png") no-repeat center;
background-size: 100% 100%;
}
.fixed {
position: fixed;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
width: 895px;
box-shadow: 0px 2px 30px 0px rgba(0, 0, 0, 0.07);
}
.sign-in-box {
width: 443px;
height: 554px;
background: rgba(255, 255, 255, 1);
border-radius: 4px;
padding: 0 26px;
float: left;
position: relative;
}
.background-left {
background: url("../../../assets/images/SigIn/login_bg.png") no-repeat center;
background-size: 100%;
float: left;
background-color: #faf8fd;
height: 554px;
width: 400px;
}
</style>
\ No newline at end of file
...@@ -34,6 +34,9 @@ if (key) { ...@@ -34,6 +34,9 @@ if (key) {
} else if (key.indexOf('ydyjy') === 0) { } else if (key.indexOf('ydyjy') === 0) {
// boe // boe
router = require('@/entry/ydyjy/router'); router = require('@/entry/ydyjy/router');
} else if (key.indexOf('gy') === 0) {
// gy
router = require('@/entry/gy/router');
} }
} }
......
...@@ -88,7 +88,8 @@ export default { ...@@ -88,7 +88,8 @@ export default {
<style scoped lang="less"> <style scoped lang="less">
.user-base-info { .user-base-info {
width: 49.5%; width: 100%;
// width: 49.5%;
height: 350px; height: 350px;
margin-right: 24px; margin-right: 24px;
border-radius: 4px; border-radius: 4px;
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
<div class="user-center"> <div class="user-center">
<div class="g-flex-between"> <div class="g-flex-between">
<base-info :infos="userInfo" @ToUpdate="ToUpdate" :fullWidth="!showAssets"></base-info> <base-info :infos="userInfo" @ToUpdate="ToUpdate" :fullWidth="!showAssets"></base-info>
<assets :infos="userInfo" v-if="showAssets" ></assets> <!-- <assets :infos="userInfo" v-if="showAssets" ></assets> -->
</div> </div>
<!-- 信息修改 --> <!-- 信息修改 -->
<div class="g-flex-between set-box"> <div class="g-flex-between set-box">
......
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