Commit 55fc7221 authored by 仇晓婷's avatar 仇晓婷

Merge branch 'product' of http://git.mes123.com/zhouyx/mes-ui into product

parents 376b47c8 7090e166
......@@ -1744,7 +1744,7 @@
"dependencies": {
"ajv": {
"version": "5.5.2",
"resolved": "https://registry.npm.taobao.org/ajv/download/ajv-5.5.2.tgz?cache=0&sync_timestamp=1597480760804&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fajv%2Fdownload%2Fajv-5.5.2.tgz",
"resolved": "https://registry.npmjs.org/ajv/-/ajv-5.5.2.tgz",
"integrity": "sha1-c7Xuyj+rZT49P5Qis0GtQiBdyWU=",
"dev": true,
"optional": true,
......@@ -1776,7 +1776,7 @@
},
"cross-spawn": {
"version": "5.1.0",
"resolved": "https://registry.npm.taobao.org/cross-spawn/download/cross-spawn-5.1.0.tgz?cache=0&sync_timestamp=1590421014780&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fcross-spawn%2Fdownload%2Fcross-spawn-5.1.0.tgz",
"resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-5.1.0.tgz",
"integrity": "sha1-6L0O/uWPz/b4+UUQoKVUu/ojVEk=",
"dev": true,
"optional": true,
......@@ -1856,7 +1856,7 @@
},
"fast-deep-equal": {
"version": "1.1.0",
"resolved": "https://registry.npm.taobao.org/fast-deep-equal/download/fast-deep-equal-1.1.0.tgz",
"resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-1.1.0.tgz",
"integrity": "sha1-wFNHeBfIa1HaqFPIHgWbcz0CNhQ=",
"dev": true,
"optional": true
......@@ -1894,7 +1894,7 @@
},
"json-schema-traverse": {
"version": "0.3.1",
"resolved": "https://registry.npm.taobao.org/json-schema-traverse/download/json-schema-traverse-0.3.1.tgz",
"resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.3.1.tgz",
"integrity": "sha1-NJptRMU6Ud6JtAgFxdXlm0F9M0A=",
"dev": true,
"optional": true
......@@ -1964,7 +1964,7 @@
},
"yallist": {
"version": "2.1.2",
"resolved": "https://registry.npm.taobao.org/yallist/download/yallist-2.1.2.tgz",
"resolved": "https://registry.npmjs.org/yallist/-/yallist-2.1.2.tgz",
"integrity": "sha1-HBH5IY8HYImkfdUS+TxmmaaoHVI=",
"dev": true,
"optional": true
......@@ -4938,7 +4938,7 @@
"dependencies": {
"commander": {
"version": "2.14.1",
"resolved": "http://r.cnpmjs.org/commander/download/commander-2.14.1.tgz",
"resolved": "https://registry.npm.taobao.org/commander/download/commander-2.14.1.tgz?cache=0&sync_timestamp=1595168224685&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fcommander%2Fdownload%2Fcommander-2.14.1.tgz",
"integrity": "sha1-IjUSPjevjKPGXfRbAm29NXsBuao="
}
}
......@@ -5467,7 +5467,7 @@
},
"crc-32": {
"version": "1.2.0",
"resolved": "http://r.cnpmjs.org/crc-32/download/crc-32-1.2.0.tgz",
"resolved": "https://registry.npm.taobao.org/crc-32/download/crc-32-1.2.0.tgz",
"integrity": "sha1-yy224puIUI4y2d0OwWk+e0Ghggg=",
"requires": {
"exit-on-epipe": "~1.0.1",
......@@ -7364,7 +7364,7 @@
},
"exit-on-epipe": {
"version": "1.0.1",
"resolved": "http://r.cnpmjs.org/exit-on-epipe/download/exit-on-epipe-1.0.1.tgz",
"resolved": "https://registry.npm.taobao.org/exit-on-epipe/download/exit-on-epipe-1.0.1.tgz",
"integrity": "sha1-C92S6H1ShdJn2qgXHQ6wYVlolpI="
},
"expand-brackets": {
......@@ -8015,7 +8015,7 @@
},
"frac": {
"version": "1.1.2",
"resolved": "http://r.cnpmjs.org/frac/download/frac-1.1.2.tgz",
"resolved": "https://registry.npm.taobao.org/frac/download/frac-1.1.2.tgz",
"integrity": "sha1-PXT39keMiKG1AgMG10fcYxPHTQs="
},
"fragment-cache": {
......@@ -15087,7 +15087,7 @@
},
"printj": {
"version": "1.1.2",
"resolved": "http://r.cnpmjs.org/printj/download/printj-1.1.2.tgz",
"resolved": "https://registry.npm.taobao.org/printj/download/printj-1.1.2.tgz",
"integrity": "sha1-2Q3rKXWoufYA+zoclOP0xTx4oiI="
},
"private": {
......@@ -20540,7 +20540,7 @@
},
"script-loader": {
"version": "0.7.2",
"resolved": "http://r.cnpmjs.org/script-loader/download/script-loader-0.7.2.tgz",
"resolved": "https://registry.npm.taobao.org/script-loader/download/script-loader-0.7.2.tgz",
"integrity": "sha1-IBbbb4byX1z1baOJFdgzeLsWa6c=",
"dev": true,
"requires": {
......@@ -21128,7 +21128,7 @@
},
"ssf": {
"version": "0.10.3",
"resolved": "http://r.cnpmjs.org/ssf/download/ssf-0.10.3.tgz",
"resolved": "https://registry.npm.taobao.org/ssf/download/ssf-0.10.3.tgz",
"integrity": "sha1-jq4fwpyQpVLnkhII+BiS1vd6yys=",
"requires": {
"frac": "~1.1.2"
......@@ -23778,7 +23778,7 @@
},
"wmf": {
"version": "1.0.2",
"resolved": "http://r.cnpmjs.org/wmf/download/wmf-1.0.2.tgz",
"resolved": "https://registry.npm.taobao.org/wmf/download/wmf-1.0.2.tgz",
"integrity": "sha1-fRnWIQcaCMK9xrfmiKnENSmMwto="
},
"word-wrap": {
......@@ -23933,7 +23933,7 @@
},
"xlsx": {
"version": "0.15.6",
"resolved": "http://r.cnpmjs.org/xlsx/download/xlsx-0.15.6.tgz",
"resolved": "https://registry.npm.taobao.org/xlsx/download/xlsx-0.15.6.tgz?cache=0&sync_timestamp=1597272342311&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fxlsx%2Fdownload%2Fxlsx-0.15.6.tgz",
"integrity": "sha1-Rh+EHW2eoag3XizSRr8jrs4IodU=",
"requires": {
"adler-32": "~1.2.0",
......@@ -23948,7 +23948,7 @@
"dependencies": {
"commander": {
"version": "2.17.1",
"resolved": "http://r.cnpmjs.org/commander/download/commander-2.17.1.tgz",
"resolved": "https://registry.npm.taobao.org/commander/download/commander-2.17.1.tgz?cache=0&sync_timestamp=1595168224685&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fcommander%2Fdownload%2Fcommander-2.17.1.tgz",
"integrity": "sha1-vXerfebelCBc6sxy8XFtKfIKd78="
}
}
......
<template>
<div class="account">
<div class="account">
<!-- <Carousel v-model="value1" autoplay :autoplay-speed="5000" loop class="zmd">
<CarouselItem>
<div class="bg bg1"></div>
......@@ -16,7 +16,7 @@
<div class="page_log">
<img class="img" src="@/assets/images/login/jz_logo.png" alt="logo" />
</div>
<img src="@/assets/images/login/ivew01.png" alt=""/>
<img src="@/assets/images/login/ivew01.png" alt="" />
</div>
<div class="login">
<div class="cen">
......@@ -31,6 +31,11 @@
</div>
<h2 class="mb20">登 录</h2>
<Login @on-submit="handleSubmit" class="form_sub">
<div class="mb20" style="height:40px;">
<Input v-model="tenantCode" size="large">
<span slot="prepend">租户号</span>
</Input>
</div>
<UserName name="username" class="user_name" value="" />
<Password name="password" class="pass_word" value="" enter-to-submit />
<div class="sub_btn">
......@@ -40,11 +45,14 @@
</div>
</div>
</div>
</div>
</div>
</template>
<script>
import iCopyright from "@/components/copyright";
import { mapActions } from "vuex";
import {
mapActions
} from "vuex";
import mixins from "../mixins";
import Oidc from "oidc-client";
import util from "@/libs/util";
......@@ -52,12 +60,15 @@ var mgr = new Oidc.UserManager(window.authConfig);
export default {
layout: "empty",
mixins: [mixins],
components: { iCopyright },
components: {
iCopyright
},
data() {
return {
value1: 0,
autoLogin: true,
imgFlag: true,
tenantCode: '000001'
};
},
created() {
......@@ -71,10 +82,16 @@ export default {
*/
handleSubmit(valid, values) {
if (valid) {
const { username, password } = values;
values.tenantcode = this.tenantCode
const {
username,
password,
tenantcode
} = values;
this.login({
username,
password
password,
tenantcode
}).then(r => {
if (r > 0) {
this.$Message.success("登录成功!");
......@@ -82,7 +99,7 @@ export default {
} else {
this.$Message.error("登录失败!");
}
}).catch(e=>{
}).catch(e => {
console.log(e)
// this.$Message.error(e.message)
});
......@@ -117,14 +134,16 @@ export default {
}
});
},
handlTrance(){
handlTrance() {
this.imgFlag = !this.imgFlag
}
}
};
</script>
<style lang="less">
@jianju: 40px;
.account {
width: 100%;
height: 100vh;
......@@ -132,6 +151,7 @@ export default {
// top: 0;
// bottom: 0;
background-image: url("../../../assets/images/login/login01.png");
.zmd {
z-index: 1;
position: absolute;
......@@ -139,23 +159,29 @@ export default {
bottom: 0;
width: 100%;
}
.bg {
width: 100%;
height: 100vh;
background-size: 100% auto;
}
.bg0 {
background-image: url("../../../assets/images/login/login01.png");
}
.bg1 {
background-image: url("../../../assets/images/login/login01.png");
}
.bg2 {
background-image: url("../../../assets/images/login/login01.png");
}
.bg3 {
background-image: url("../../../assets/images/login/login01.png");
}
.main {
z-index: 55;
height: 603px;
......@@ -171,18 +197,30 @@ export default {
background: url("../../../assets/images/login/login02.jpg") no-repeat -70px 0px;
background-size: 80%;
display: flex;
h2{ padding: 4px 0 15px 0;}
h2 {
padding: 4px 0 15px 0;
}
.ad {
flex: 1;
text-align: center;
.page_log{
.page_log {
display: block;
width: 304px;
height: 72px;
}
.img { margin-top:30px; }
img { margin-top:23%; }
.img {
margin-top: 30px;
}
img {
margin-top: 23%;
}
}
.login {
background-color: white;
width: 410px;
......@@ -190,19 +228,23 @@ export default {
display: flex;
// align-items: center;
flex-direction: row;
.cen {
width: 100%;
.log_code_box{
.log_code_box {
text-align: right;
height: 110px;
margin: 0 -40px 0 0;
.log_code{
.log_code {
position: relative;
cursor: pointer;
width: 90px;
height: 85PX;
float: right;
.sanjiao{
.sanjiao {
width: 90px;
height: 90px;
border-bottom: 90px solid #ffffff;
......@@ -213,13 +255,16 @@ export default {
}
}
}
.ivu-input-wrapper {
margin-bottom: 6px;
}
.sub_btn{
.shadown{
.sub_btn {
.shadown {
padding: 30px 0 0 0;
button{
button {
height: 50px;
border-radius: 25px;
box-shadow: 0px 9px 11px 3px #c2d6ec;
......@@ -238,14 +283,18 @@ export default {
}
}
}
.animation-enter-to,.animation-leave-to{
.animation-enter-to,
.animation-leave-to {
animation: mymove 1s 1s linear;
}
@keyframes mymove {
0%{
0% {
transform: translateX(0px);
}
100%{
100% {
transform: translateX(-45px);
}
}
......
......@@ -22,13 +22,15 @@ export const actions = {
dispatch
}, {
username = '',
password = ''
password = '',
tenantcode=''
} = {}) {
return new Promise((resolve, reject) => {
// 开始请求登录接口
AccountLogin({
username,
password
password,
tenantcode
})
.then(async res => {
// 设置 cookie 一定要存 uuid 和 token 两个 cookie
......@@ -85,7 +87,7 @@ export const actions = {
sessionStorage.clear();
localStorage.clear();
//util.cookies.set('tenantCode', res.result.tenantCode );
$nuxt.$router.push("/account/login?tenant="+util.cookies.get('tenantCode'));
$nuxt.$router.push("/account/login");
}
if (confirm) {
......
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