| | |
| | | <template> |
| | | <div class="login-container"> |
| | | <div class="title-one"> |
| | | <span>拜城县众泰煤焦化有限公司</span> |
| | | 欢迎访问 |
| | | </div> |
| | | <div class="title-two"> |
| | | <span>智能化安全管理技术平台</span> |
| | | 隐患排查体系综合管控系统 |
| | | </div> |
| | | <div class="login-main"> |
| | | <div class="login-main-pic"></div> |
| | |
| | | </div> |
| | | </div> |
| | | <div class="bottom-container"> |
| | | <span style="text-align: center">Copyright©2022 新疆阿克苏拜城众泰煤焦化有限公司 版权所有</span> |
| | | Copyright©2023 苏州国科鸿宇智能科技有限公司 版权所有 |
| | | </div> |
| | | <!-- <el-row>--> |
| | | <!-- <el-col :xs="24" :sm="24" :lg="12">--> |
| | |
| | | </template> |
| | | |
| | | <script> |
| | | import { loginByUsername } from '@/api/login' |
| | | import { getAccount,loginByUsername,getUserInfo } from '@/api/login' |
| | | import { getToken, setToken, removeToken } from '@/utils/auth' |
| | | import Cookies from 'js-cookie' |
| | | import { initRouter } from '@/utils/router' |
| | |
| | | Cookies.set('token_expired_at', data.tokenexpired) |
| | | _this.$store.commit('SET_NAME', data.realname) |
| | | _this.$store.commit('SET_USER_TYPE', data.type) |
| | | //换取账号密码 |
| | | getUserInfo().then(res => { |
| | | if (res.data.code == 200) { |
| | | loginForm.department = res.data.result.department |
| | | // loginForm.department = "公司领导" |
| | | getAccount(loginForm).then(res => { |
| | | if (res.data.code == 200) { |
| | | //缓存账号密码 |
| | | Cookies.set("hiddenDangerUsername",res.data.result.username) |
| | | Cookies.set("hiddenDangerPassword",res.data.result.password) |
| | | } else { |
| | | this.$message({type: 'error', message: res.data.msg, duration: 3000}) |
| | | } |
| | | }) |
| | | |
| | | } else { |
| | | this.$message({type: 'error', message: "用户信息获取失败!请重试", duration: 3000}) |
| | | } |
| | | }) |
| | | |
| | | // 加载菜单 |
| | | initRouter(_this) |
| | | _this.$router.replace('/') |
| | |
| | | .login-container { |
| | | min-height: 100%; |
| | | width: 100%; |
| | | background: url("../../assets/bg.jpg") center no-repeat; |
| | | background: url("../../assets/bg_login.png") center no-repeat; |
| | | //background-size: auto 100%; |
| | | // background-color: #2d3a4b; |
| | | overflow: hidden; |
| | |
| | | .title-one{ |
| | | width: 360px; |
| | | height: 42px; |
| | | font-size: 30px; |
| | | font-size: 36px; |
| | | text-align: center; |
| | | font-family: PingFangSC-Semibold, PingFang SC; |
| | | font-weight: 600; |
| | | color: #FFFFFF; |
| | | color: #1851DC; |
| | | line-height: 42px; |
| | | text-shadow: 0px 8px 10px rgba(16, 57, 193, 0.3); |
| | | margin: 0 auto; |
| | | margin-top: 120px; |
| | | margin-top: 160px; |
| | | } |
| | | .title-two{ |
| | | width: 473px; |
| | | width: 80%; |
| | | height: 61px; |
| | | font-size: 43px; |
| | | font-size: 48px; |
| | | font-family: PingFangSC-Semibold, PingFang SC; |
| | | font-weight: 600; |
| | | color: #FFFFFF; |
| | | color: #1851DC; |
| | | text-align: center; |
| | | line-height: 61px; |
| | | letter-spacing: 10px; |
| | | text-indent: 10px; |
| | | text-shadow: 0px 8px 10px rgba(16, 57, 193, 0.3); |
| | | margin: 0 auto; |
| | | margin-top: 5px; |
| | | margin-top: 20px; |
| | | } |
| | | .login-main{ |
| | | display: flex; |
| | | background: linear-gradient(270deg, #FFFFFF 0%, #FFFFFF 100%); |
| | | box-shadow: 0px 20px 40px 0px rgba(34, 0, 255, 0.7); |
| | | box-shadow: 0px 20px 40px 0px rgba(1, 140, 255, 0.7); |
| | | width:1036px; |
| | | min-height: 474px; |
| | | min-height: 476px; |
| | | margin:0 auto; |
| | | margin-top: 60px; |
| | | border-radius: 8px; |
| | | overflow: hidden; |
| | | .login-main-pic{ |
| | | display: inline-block; |
| | | height: 474px; |
| | | height: 476px; |
| | | width: 572px; |
| | | background: url("../../assets/img_bg_login.png") center no-repeat; |
| | | background: url("../../assets/bg.jpg") center no-repeat; |
| | | background-size: 100% auto; |
| | | } |
| | | .login-main-form{ |
| | | display: inline-block; |
| | |
| | | } |
| | | } |
| | | .bottom-container{ |
| | | width:600px; |
| | | width: 600px; |
| | | height: 42px; |
| | | font-family: PingFangSC-Semibold, PingFang SC; |
| | | line-height: 42px; |
| | | text-shadow: 0px 8px 10px rgba(16, 57, 193, 0.3); |
| | | margin: 0 auto; |
| | | margin-top: 150px; |
| | | text-align: center; |
| | | } |
| | | } |
| | | |