Commit b74ca67e authored by linxin's avatar linxin

add

parents 557f9fd5 7c987057
Pipeline #4656 canceled with stages
......@@ -13,5 +13,5 @@ module.exports = merge(prodEnv, {
filePath: '"http://180.104.121.66:8088/r/api/app/fileViewSvc?sysName=XCMG_DEV&apiName=file_view&"',
ocrPath: '"http://180.104.121.66:8088/r/api"',
appId: '"com.xcmg.app.dev"',
currentVersion: '"1.6.1"',
currentVersion: '"1.6.3"',
})
......@@ -101,7 +101,7 @@
</div>
</h-content>
<bottom-tab class="add-box">
<tab-button v-if="!isReadOnly" class="before" @click.native="handSave">同步电子签</tab-button>
<tab-button v-if="!isReadOnly" class="before" @click.native="handSave">保存</tab-button>
<tab-button v-if="!isReadOnly" class="next" @click.native="isSubmit">提交</tab-button>
<tab-button v-if="isReadOnly" class="before" @click.native="$routeGo()">上一步</tab-button>
</bottom-tab>
......@@ -512,21 +512,21 @@ export default {
},
// 同步电子签
handSave () {
// hlsPopup.showLongCenter('保存成功!')
let vm = this
let url = process.env.basePath + 'syn_content_app'
let param = {
project_id: window.localStorage.project_id,
}
vm.hlsPopup.showLoading('请稍候')
vm.hlsHttp.post(url, param).then(function (res) {
vm.hlsPopup.hideLoading()
if (res.result === 'S') {
vm.hlsPopup.showSuccess('同步成功')
} else {
vm.hlsPopup.showLongCenter(res.message)
}
})
hlsPopup.showLongCenter('保存成功!')
// let vm = this
// let url = process.env.basePath + 'syn_content_app'
// let param = {
// project_id: window.localStorage.project_id,
// }
// vm.hlsPopup.showLoading('请稍候')
// vm.hlsHttp.post(url, param).then(function (res) {
// vm.hlsPopup.hideLoading()
// if (res.result === 'S') {
// vm.hlsPopup.showSuccess('同步成功')
// } else {
// vm.hlsPopup.showLongCenter(res.message)
// }
// })
},
isSubmit () {
let vm = this
......
......@@ -177,7 +177,7 @@
</div>
</h-content>
<bottom-tab v-if="!flag">
<tab-button class="save" @click.native="handSave">同步电子签</tab-button>
<!-- <tab-button class="save" @click.native="handSave">同步电子签</tab-button> -->
<tab-button class="approve" @click.native="checkStatus">发车申请</tab-button>
</bottom-tab>
<div class="bottom-pop">
......
......@@ -62,7 +62,7 @@ export default {
beforeRouteEnter (to, from, next) {
next(vm => {
if (from.name !== 'PrivacyPolicy') {
vm.getAccessToken()
// vm.getAccessToken()
}
if (!window.localStorage.getItem('isReadPolicy')) {
setTimeout(() => {
......@@ -124,21 +124,25 @@ export default {
// 极光推送
})
},
getAccessToken () {
async getAccessToken () {
let vm = this
let url = process.env.loginPath + 'appadmin'
let param = {}
// vm.hlsPopup.showLoading('请稍等')
vm.$post(url, param).then(function (res) {
let res = await vm.$post(url, param)
// vm.hlsPopup.hideLoading()
if (res) {
window.localStorage.setItem('access_token', res.access_token)
vm.updateVersion() // 版本更新
})
return true
}
},
access: function () {
async access () {
document.getElementById('passwordInput').blur()
document.activeElement.blur()
let flag = await this.getAccessToken()
let vm = this
if (flag) {
if (!vm.username || vm.username === undefined) {
vm.hlsPopup.showLongCenter('请输入用户名')
} else if (!vm.password || vm.password === undefined) {
......@@ -147,6 +151,7 @@ export default {
hlsPopup.showLoading('正在登录')
vm.login()
}
}
},
registerNew: function () {
document.getElementById('passwordInput').blur()
......
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