提交 ce2551c5 authored 作者: huaxinzhu's avatar huaxinzhu

云仓新功能

上级 2e5e6aaa
......@@ -9,3 +9,21 @@ export default {
name: 'App'
}
</script>
<style>
body {
font-family:Microsoft YaHei,Arial,Helvetica,sans-serif;
}
/* 在全局CSS里引用: */
/* 滚动条宽度 */
::-webkit-scrollbar {
width: 10px;
height: 10px;
}
/* 滚动条的滑块 */
::-webkit-scrollbar-thumb {
background-color: #c0ccda;
border-radius: 6px;
}
</style>
......@@ -4,7 +4,10 @@ import Router from 'vue-router'
Vue.use(Router)
/* Layout */
import Layout from '@/layout'
import Layout from '@/layout';
import Entry from '@/views/entry';
/**
* Note: 路由配置项
......@@ -57,7 +60,43 @@ export const constantRoutes = [
component: (resolve) => require(['@/views/error/401'], resolve),
hidden: true
},
// 阅读协议
{
path: '/agreement',
component: (resolve) => require(['@/views/entry/agreement'], resolve),
hidden: true
},
// 主体信息 fillStoreInf
{
path: '/fillMainInf',
component: (resolve) => require(['@/views/entry/fillMainInf'], resolve),
hidden: true
},
// 品牌信息
{
path: '/fillBrandInf',
component: (resolve) => require(['@/views/entry/fillBrandInf'], resolve),
hidden: true
},
// 店铺信息
{
path: '/fillShopInf',
component: (resolve) => require(['@/views/entry/fillShopInf'], resolve),
hidden: true
},
// 提交审核
{
path: '/reviewing',
component: (resolve) => require(['@/views/entry/reviewing'], resolve),
hidden: true
},
// 审核失败
{
path: '/reviewFail',
component: (resolve) => require(['@/views/entry/reviewFail'], resolve),
hidden: true
},
/*{
path: '',
component: Layout,
redirect: 'index',
......@@ -69,6 +108,19 @@ export const constantRoutes = [
meta: { title: '首页', icon: 'dashboard', noCache: true, affix: true }
}
]
},*/
{
path: '',
component: Entry,
redirect: 'index',
children: [
{
path: 'index',
component: (resolve) => require(['@/views/index'], resolve),
name: '首页',
meta: { title: '首页', icon: 'dashboard', noCache: true, affix: true }
}
]
},
{
path: '/user',
......
......@@ -3,65 +3,46 @@
<script>
export default {
name: "Login2",
created() {
this.gotosso()
this.gotosso()
},
methods: {
getCookie() {
var de = this.$store.commit("SET_TOKEN")
console.log("SET_TOKEN",de)
// const password = Cookies.get("password");
// const rememberMe = Cookies.get('rememberMe')
// this.loginForm = {
// username: username === undefined ? this.loginForm.username : username,
// password: password === undefined ? this.loginForm.password : decrypt(password),
// rememberMe: rememberMe === undefined ? false : Boolean(rememberMe)
// };
},
gotosso(){
var ticket = this.$route.query.ticket
// let data = this.getUrlParam('ticket')
// this.loading = true
this.$store.dispatch('Login', {"ticket":ticket}).then((res) => {
// console.log(123456)
// console.log(res)
// return false
// debugger
if(res.token != ""){
this.$router.push({ path:'/' })
}else{
this.$store.dispatch('Statistic')
this.$store.dispatch('FedLogOut')
var ssa = window.location.host
setTimeout(function (){
if(ssa =='localhost:1024'){
window.location.href='http://sso.jxhh.com/logout?redirect=http://'+ssa+'/login'
}else{
window.location.href='http://sso.jxhh.com/logout?redirect=http://'+ssa+'/login'
}
}, 1000)
}
this.loading = false
})
.catch(() => {
debugger
console.log(222222222222)
this.$store.dispatch('FedLogOut')
var ssa = window.location.host
setTimeout(function (){
if(ssa =='localhost:1024'){
window.location.href='http://sso.jxhh.com/logout?redirect=http://'+ssa+'/login'
}else{
window.location.href='http://sso.jxhh.com/logout?redirect=http://'+ssa+'/login'
}
}, 1000)
this.loading = false
})
},
getCookie() {
var de = this.$store.commit("SET_TOKEN")
},
gotosso() {
var ticket = this.$route.query.ticket
this.$store.dispatch('Login', {"ticket": ticket}).then((res) => {
if (res.token != "") {
this.$router.push({path: '/'})
} else {
this.$store.dispatch('Statistic')
this.$store.dispatch('FedLogOut')
var ssa = window.location.host
setTimeout(function () {
if (ssa == 'localhost:1024') {
window.location.href = 'http://sso.jxhh.com/logout?redirect=http://' + ssa + '/login'
} else {
window.location.href = 'http://sso.jxhh.com/logout?redirect=http://' + ssa + '/login'
}
}, 1000)
}
this.loading = false
})
.catch(() => {
this.$store.dispatch('FedLogOut')
var ssa = window.location.host
setTimeout(function () {
if (ssa == 'localhost:1024') {
window.location.href = 'http://sso.jxhh.com/logout?redirect=http://' + ssa + '/login'
} else {
window.location.href = 'http://sso.jxhh.com/logout?redirect=http://' + ssa + '/login'
}
}, 1000)
this.loading = false
})
},
}
};
......
<script>
export default {
created() {
const { params, query } = this.$route
const { path } = params
this.$router.replace({ path: '/' + path, query })
},
render: function(h) {
return h() // avoid warning message
export default {
created() {
const {params, query} = this.$route
const {path} = params;
this.$router.replace({path: '/' + path, query})
},
render: function (h) {
return h()
}
}
}
</script>
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论