e639032f by renchao@pashanhoo.com

style:登录

1 parent 0d04d432
......@@ -19,231 +19,231 @@
</div>
</template>
<script>
import sidebarLeft from "./Sidebar/sidebarLeft";
import sidebarRight from "./Sidebar/sidebarRight";
import { logout } from "@/api/login.js";
import { mapGetters } from "vuex";
export default {
components: {
sidebarLeft,
sidebarRight,
},
computed: {
...mapGetters(["userInfo"]),
userName () {
return this.userInfo ? this.userInfo.name : ""
}
},
methods: {
onCancel () {
logout()
.then((res) => {
sessionStorage.removeItem("token");
this.$store.dispatch("user/resetState");
this.$store.dispatch("permission/resetRoutes");
this.$router.replace({
path: "/jg"
import sidebarLeft from "./Sidebar/sidebarLeft";
import sidebarRight from "./Sidebar/sidebarRight";
import { logout } from "@/api/login.js";
import { mapGetters } from "vuex";
export default {
components: {
sidebarLeft,
sidebarRight,
},
computed: {
...mapGetters(["userInfo"]),
userName () {
return this.userInfo ? this.userInfo.name : ""
}
},
methods: {
onCancel () {
logout()
.then((res) => {
sessionStorage.removeItem("token");
this.$store.dispatch("user/resetState");
this.$store.dispatch("permission/resetRoutes");
this.$router.replace({
path: "/login"
})
})
})
.catch((error) => {
})
.catch((error) => {
})
}
}
}
}
</script>
<style lang="scss" scoped>
.menubg {
height: 34px;
width: 130px !important;
text-align: center;
color: #ffffff;
background: url("~@/image/navbar.png") no-repeat;
background-size: 100% 100%;
}
/deep/.el-menu-item {
@extend .menubg;
}
/deep/.el-submenu {
@extend .menubg;
}
/deep/.el-submenu__title {
height: 34px;
color: #ffffff;
}
/deep/.el-submenu__title span {
font-size: 14px;
}
.sidebarLeft {
position: relative;
top: 13px;
width: 30%;
}
/deep/.el-menu {
display: flex;
justify-content: space-between;
width: 100%;
background: transparent !important;
}
/deep/.el-menu-item {
flex: 1;
width: 100%;
}
.sidebarRight {
position: relative;
top: 13px;
width: 30%;
}
// 导航选中背景色
.xuanzhong {
background: url("~@/image/selNavbar.png") no-repeat;
background-size: 100% 100%;
color: #ffffff !important;
font-weight: 700;
}
/deep/.el-menu-item:hover {
@extend .xuanzhong;
}
/deep/.el-submenu__title:hover {
@extend .xuanzhong;
}
/deep/.el-menu--horizontal .el-menu-item:not(.is-disabled):focus {
@extend .xuanzhong;
}
/deep/.is-active {
@extend .xuanzhong;
}
.navbar {
height: $headerHeight;
overflow: hidden;
position: relative;
display: flex;
align-items: center;
padding: 0 20px;
justify-content: space-between;
background: url("~@/image/header.png") no-repeat;
background-size: 100% 100%;
.user {
font-size: 12px;
.menubg {
height: 34px;
width: 130px !important;
text-align: center;
color: #ffffff;
position: absolute;
right: 20px;
top: 0;
cursor: pointer;
background: url("~@/image/navbar.png") no-repeat;
background-size: 100% 100%;
}
.closeStyle {
margin-right: 5px;
}
/deep/.el-menu-item {
@extend .menubg;
}
.title {
position: absolute;
left: 0;
top: 10px;
bottom: 0;
right: 0;
margin: 0 auto;
font-size: 32px;
/deep/.el-submenu {
@extend .menubg;
}
/deep/.el-submenu__title {
height: 34px;
color: #ffffff;
font-weight: 700;
text-align: center;
}
.right-menu {
float: right;
height: 100%;
line-height: 50px;
/deep/.el-submenu__title span {
font-size: 14px;
}
.sidebarLeft {
position: relative;
top: 13px;
width: 30%;
}
/deep/.el-menu {
display: flex;
align-items: center;
justify-content: space-between;
width: 100%;
background: transparent !important;
}
.shutdown {
font-size: 20px;
margin-left: 15px;
cursor: pointer;
}
/deep/.el-menu-item {
flex: 1;
width: 100%;
}
.organization-item {
margin-right: 40px;
margin-top: -40px !important;
}
.sidebarRight {
position: relative;
top: 13px;
width: 30%;
}
// 导航选中背景色
.xuanzhong {
background: url("~@/image/selNavbar.png") no-repeat;
background-size: 100% 100%;
color: #ffffff !important;
font-weight: 700;
}
/deep/.el-menu-item:hover {
@extend .xuanzhong;
}
/deep/.el-submenu__title:hover {
@extend .xuanzhong;
}
.item {
margin-right: 40px;
margin-top: -20px;
line-height: 18.4px;
/deep/.el-menu--horizontal .el-menu-item:not(.is-disabled):focus {
@extend .xuanzhong;
}
/deep/.is-active {
@extend .xuanzhong;
}
.navbar {
height: $headerHeight;
overflow: hidden;
position: relative;
display: flex;
align-items: center;
padding: 0 20px;
justify-content: space-between;
background: url("~@/image/header.png") no-repeat;
background-size: 100% 100%;
.user {
font-size: 12px;
color: #ffffff;
position: absolute;
right: 20px;
top: 0;
cursor: pointer;
position: relative;
.item-box {
position: absolute;
top: -5px;
left: 3px;
width: 100%;
min-width: 25px;
height: 25px;
cursor: pointer;
z-index: 100;
.closeStyle {
margin-right: 5px;
}
}
&:focus {
outline: none;
.title {
position: absolute;
left: 0;
top: 10px;
bottom: 0;
right: 0;
margin: 0 auto;
font-size: 32px;
color: #ffffff;
font-weight: 700;
text-align: center;
}
.right-menu-item {
display: inline-block;
.right-menu {
float: right;
height: 100%;
font-size: 18px;
color: #fff;
vertical-align: text-bottom;
line-height: 50px;
display: flex;
align-items: center;
&.hover-effect {
.shutdown {
font-size: 20px;
margin-left: 15px;
cursor: pointer;
transition: background 0.3s;
display: flex;
align-items: center;
}
.organization-item {
margin-right: 40px;
margin-top: -40px !important;
}
&:hover {
background: rgba(0, 0, 0, 0.025);
.item {
margin-right: 40px;
margin-top: -20px;
line-height: 18.4px;
cursor: pointer;
position: relative;
.item-box {
position: absolute;
top: -5px;
left: 3px;
width: 100%;
min-width: 25px;
height: 25px;
cursor: pointer;
z-index: 100;
}
}
}
.avatar-wrapper {
position: relative;
display: flex;
height: 40px;
align-items: center;
&:focus {
outline: none;
}
.user-avatar {
cursor: pointer;
width: 35px;
height: 35px;
border-radius: 50%;
.right-menu-item {
display: inline-block;
height: 100%;
font-size: 18px;
color: #fff;
vertical-align: text-bottom;
&.hover-effect {
cursor: pointer;
transition: background 0.3s;
display: flex;
align-items: center;
&:hover {
background: rgba(0, 0, 0, 0.025);
}
}
}
.el-icon-caret-bottom {
cursor: pointer;
position: absolute;
right: -15px;
top: 17px;
font-size: 12px;
.avatar-wrapper {
position: relative;
display: flex;
height: 40px;
align-items: center;
.user-avatar {
cursor: pointer;
width: 35px;
height: 35px;
border-radius: 50%;
}
.el-icon-caret-bottom {
cursor: pointer;
position: absolute;
right: -15px;
top: 17px;
font-size: 12px;
}
}
}
}
}
</style>
......
/*
* @Description: 此文件主要创建 axios 实例,然后添加请求拦截器和响应拦截器
* @Autor: renchao
* @LastEditTime: 2023-04-27 17:09:51
* @LastEditTime: 2023-05-25 14:07:28
*/
import Vue from 'vue'
import axios from "axios";
......@@ -72,7 +72,7 @@ function handleErrorData (status) {
let code = Vue.prototype.BASE_API.CODE
if (code == 'BDCSBPT') {
router.replace({
path: "/sb",
path: "/login",
query: {
redirect: router.history.current.fullPath,
},
......
......@@ -234,7 +234,6 @@
},
methods: {
uploadRecord (file) {
console.log(file, 'eee11111111111111');
this.requested = true
this.files = file;
const extension = file.name.split('.')[1] === 'xml'
......