|
|
@@ -4,13 +4,15 @@
|
|
|
<nav class="x-navbar">
|
|
|
<div class="container">
|
|
|
<div class="navbar-header">
|
|
|
- <input type="hidden" name="iconUrl" value="/static/img/icon_mall_index.png">
|
|
|
- <a class="navbar-brand" id="navbar-brand">
|
|
|
- 欢迎登录
|
|
|
+ <input type="hidden" name="iconUrl" value="">
|
|
|
+ <a class="navbar-brand" :href="JSON.parse(loginStyle.returnHomeUrl).url || ''">
|
|
|
+ <img :src="loginStyle.logoUrl" alt="">
|
|
|
+ <span>{{loginStyle.title || ''}}</span>
|
|
|
</a>
|
|
|
</div>
|
|
|
<div class="collapse navbar-collapse navbar-right">
|
|
|
- <a href="http://www.ubtob.com">优软云首页</a> <a href="http://uas.ubtob.com/serve#/">帮助</a>
|
|
|
+ <a :href="JSON.parse(loginStyle.returnHomeUrl).url || ''">{{JSON.parse(loginStyle.returnHomeUrl).name || ''}}</a>
|
|
|
+ <a href="http://uas.ubtob.com/serve#/" v-if="JSON.parse(loginStyle.returnHomeUrl).needHelp">帮助</a>
|
|
|
</div>
|
|
|
</div>
|
|
|
</nav>
|
|
|
@@ -19,8 +21,16 @@
|
|
|
<div class="x-banner-wrap">
|
|
|
<div class="x-banner">
|
|
|
<ul class="list-unstyled">
|
|
|
- <li id="bgStyle">
|
|
|
- <a>
|
|
|
+ <li id="bgStyle" v-bind:style="{ background: `url(${loginStyle.bgUrl}) center center/auto 100% no-repeat ${loginStyle.bgColor}` }">
|
|
|
+ <a :href="loginStyle.bgLink" v-if="loginStyle.bgLink">
|
|
|
+ <div class="inner">
|
|
|
+ <div class="x-title x-text-0"></div>
|
|
|
+ <div class="x-subtitle x-text-0"></div>
|
|
|
+ <div class="x-btn-group">
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </a>
|
|
|
+ <a v-else style="cursor: default">
|
|
|
<div class="inner">
|
|
|
<div class="x-title x-text-0"></div>
|
|
|
<div class="x-subtitle x-text-0"></div>
|
|
|
@@ -120,6 +130,8 @@
|
|
|
</div>
|
|
|
<loading v-show="isShowLoading"/>
|
|
|
</div>
|
|
|
+ <!--尾部-->
|
|
|
+ <div v-html="loginStyle.footUrl || ''" class="footer"></div>
|
|
|
</div>
|
|
|
</template>
|
|
|
|
|
|
@@ -216,16 +228,9 @@
|
|
|
mounted () {
|
|
|
this.$nextTick(() => {
|
|
|
this.getUrl()
|
|
|
- })
|
|
|
- this.$nextTick(() => {
|
|
|
- this.getLoginStyle()
|
|
|
- })
|
|
|
- this.$nextTick(() => {
|
|
|
if (this.appId === 'mall' || this.appId === 'home') {
|
|
|
this.getCookie()
|
|
|
}
|
|
|
- })
|
|
|
- this.$nextTick(() => {
|
|
|
this.validUserName()
|
|
|
})
|
|
|
},
|
|
|
@@ -233,11 +238,11 @@
|
|
|
enterprise () {
|
|
|
let chooseEnterprise = this.$store.state.login.chooseRegisterEnterprise.choose.data
|
|
|
return chooseEnterprise
|
|
|
+ },
|
|
|
+ loginStyle () {
|
|
|
+ console.log('22222', this.$store.state.login.loginStyle.data)
|
|
|
+ return this.$store.state.login.loginStyle.data.content ? this.$store.state.login.loginStyle.data.content : ''
|
|
|
}
|
|
|
- // loginUrl () {
|
|
|
- // console.log(this.$store.state.login.loginStyle.loginStyle.data)
|
|
|
- // return this.$store.state.login.loginStyle.loginStyle.data
|
|
|
- // }
|
|
|
},
|
|
|
methods: {
|
|
|
// 获取用户错误次数
|
|
|
@@ -297,45 +302,10 @@
|
|
|
this.appId = request['appId'] || ''
|
|
|
this.returnUrl = request['returnURL'] || ''
|
|
|
this.baseUrl = request['baseUrl'] || ''
|
|
|
- if (this.appId === 'home') {
|
|
|
+ if (this.appId === 'home' || this.appId === 'mall') {
|
|
|
this.checkedRemember = true
|
|
|
}
|
|
|
},
|
|
|
- // 获取后台返回的数据
|
|
|
- getLoginStyle () {
|
|
|
- this.$http.get(`/sso/login/page/style`, {params: {appId: this.appId}})
|
|
|
- .then(response => {
|
|
|
- if (response.data.success) {
|
|
|
- let logoUrlStyle = response.data.content.logoUrl
|
|
|
- let bgUrl = response.data.content.bgUrl
|
|
|
- let bgColor = response.data.content.bgColor
|
|
|
- let bgLink = response.data.content.bgLink
|
|
|
- let title = response.data.content.title || '欢迎登录'
|
|
|
- let appId = response.data.content.appId
|
|
|
- let nb = document.getElementById('navbar-brand')
|
|
|
- nb.style.backgroundImage = 'url(' + logoUrlStyle + ')'
|
|
|
- nb.innerHTML = title
|
|
|
- if (appId === 'mall') {
|
|
|
- this.checkedRemember = true
|
|
|
- nb.href = 'https://www.usoftmall.com/'
|
|
|
- }
|
|
|
- let bg = document.getElementById('bgStyle')
|
|
|
- bg.style.backgroundImage = 'url(' + bgUrl + ')'
|
|
|
- bg.style.backgroundColor = bgColor
|
|
|
- if (bgLink) {
|
|
|
- bg.onclick = function () {
|
|
|
- window.location.href = bgLink
|
|
|
- }
|
|
|
- }
|
|
|
- } else {
|
|
|
- return Promise.reject(response.data)
|
|
|
- }
|
|
|
- }).catch(err => {
|
|
|
- // console.log(err)
|
|
|
- this.$message.error(err.errMsg)
|
|
|
- })
|
|
|
- },
|
|
|
-// 忘记密码
|
|
|
goForgetPassword () {
|
|
|
let url = `/reset/forgetPasswordValidationAccount?${this.queryLink}`
|
|
|
document.getElementById('forget').href = url
|
|
|
@@ -489,8 +459,6 @@
|
|
|
// 设置cookie
|
|
|
setCookie (cName, cPwd, exdays) {
|
|
|
let exdate = new Date()
|
|
|
- // let len = cPwd.substring(0)
|
|
|
- // cPwd = cPwd.replace(len, '***')
|
|
|
exdate.setTime(exdate.getTime() + 24 * 60 * 60 * 1000 * exdays)
|
|
|
window.document.cookie = 'userName' + '=' + cName + ';path=/;expires=' + exdate.toGMTString()
|
|
|
window.document.cookie = 'userPwd' + '=' + cPwd + ';path=/;expires=' + exdate.toGMTString()
|
|
|
@@ -503,11 +471,9 @@
|
|
|
let arr2 = arr[i].split('=')
|
|
|
if (arr2[0].trim() === 'userName') {
|
|
|
this.login.username = arr2[1]
|
|
|
- // console.log('get', this.login.username)
|
|
|
}
|
|
|
if (arr2[0].trim() === 'userPwd') {
|
|
|
this.login.password = arr2[1]
|
|
|
- // console.log('get', this.login.password)
|
|
|
}
|
|
|
if (this.login.username && this.login.username) {
|
|
|
this.checked = true
|
|
|
@@ -532,15 +498,30 @@
|
|
|
.container{
|
|
|
position: relative;
|
|
|
width: 990px!important;
|
|
|
+ height: 80px;
|
|
|
+ .navbar-header{
|
|
|
+ height: 80px;
|
|
|
+ line-height: 80px;
|
|
|
+ }
|
|
|
a.navbar-brand{
|
|
|
- padding: 0 0 0 85px;
|
|
|
+ overflow: hidden;
|
|
|
+ padding: 0px;
|
|
|
height: inherit;
|
|
|
line-height: inherit;
|
|
|
font-family: "\5FAE\8F6F\96C5\9ED1";
|
|
|
font-size: 24px;
|
|
|
font-weight: 400;
|
|
|
color: #888;
|
|
|
- background: url(/images/all/icon_brand.png) left center no-repeat;
|
|
|
+ img{
|
|
|
+ margin: 28px 8px 0 0;
|
|
|
+ max-width: 80px;
|
|
|
+ max-height: 27px;
|
|
|
+ vertical-align: middle;
|
|
|
+ float: left;
|
|
|
+ }
|
|
|
+ span{
|
|
|
+ float: left;
|
|
|
+ }
|
|
|
}
|
|
|
.collapse{
|
|
|
a{
|
|
|
@@ -649,7 +630,9 @@
|
|
|
li{
|
|
|
width: 100%;
|
|
|
height: 475px;
|
|
|
- background: url(/images/all/banner.jpg) center center / auto 100% no-repeat rgb(202, 202, 214);
|
|
|
+ .inner{
|
|
|
+ height: 100%;
|
|
|
+ }
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
@@ -748,4 +731,7 @@
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
+ .footer{
|
|
|
+ padding: 50px 0;
|
|
|
+ }
|
|
|
</style>
|