Commit 710252f2 authored by 张超's avatar 张超 🎱

Merge branch 'publish' into auth

hebing
parents ff135eb5 415229be
...@@ -16,7 +16,6 @@ ...@@ -16,7 +16,6 @@
</noscript> </noscript>
<script> <script>
window.__data = { window.__data = {
token : "<%= process.env.NODE_ENV === 'development' ? 'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6MjA4NSwibmFtZSI6IuWKs-eQquWzsCIsImFjY291bnQiOiJsYW9xaWZlbmciLCJlbWFpbCI6Imxhb3FpZmVuZ0BkdWliYS5jb20uY24iLCJtb2JpbGUiOiIxMzQ1Njc3NDE1MyIsImRpbmdVc2VySWQiOiI1MDY5MDYyOTIxMjkxMDAxIiwibW9kZWxBdXRob3JpemUiOmZhbHNlLCJsb2dpblRpbWVvdXQiOjgzMzUzLCJnbXRDcmVhdGUiOjE1MzQ0MTIwMTUwMDAsImdtdE1vZGlmaWVkIjoxNTczODgyMDk2MDAwLCJzeXN0ZW1JZFNldCI6WzAsMSwzNCwyMjcsMzYsMzcsMjMxLDIwMyw0NCwxOSwyMSwyNDYsMjMsMjQ5LDI1LDI3LDMwXSwiaWF0IjoxNTc4Mjc3OTg5fQ.mm6T34NuMBwTKaLBbVOI5AqGQNC9rwfiAdIv8c4C4_I' : '$TOKEN$' %>",
apiHost : "<%= process.env.NODE_ENV === 'development' ? '//beacon.duibadev.com.cn' : '$API_HOST$' %>" apiHost : "<%= process.env.NODE_ENV === 'development' ? '//beacon.duibadev.com.cn' : '$API_HOST$' %>"
} }
</script> </script>
......
...@@ -11,6 +11,7 @@ ...@@ -11,6 +11,7 @@
<script> <script>
import i18n from "./i18n"; import i18n from "./i18n";
import {SSO_VERIFY_PAGE_URL} from "./config"; import {SSO_VERIFY_PAGE_URL} from "./config";
import {getCookie} from "./api/utils";
const errorTipsArr = [ const errorTipsArr = [
'', '',
...@@ -29,13 +30,15 @@ ...@@ -29,13 +30,15 @@
} }
}, },
mounted() { mounted() {
if (!window['zeroing_token']) { let sso_ticket = getCookie('sso_ticket');
if (!sso_ticket) {
this.dealError(1); this.dealError(1);
} }
}, },
computed: { computed: {
showErrorTips() { showErrorTips() {
return !window['zeroing_token'] || !this.$route.matched || this.$route.matched.length === 0; let sso_ticket = getCookie('sso_ticket');
return !sso_ticket || !this.$route.matched || this.$route.matched.length === 0;
}, },
errorTipsStr() { errorTipsStr() {
return this.errorTips + ' ' + this.$t('Jump after', {cd: this.cd}); return this.errorTips + ' ' + this.$t('Jump after', {cd: this.cd});
...@@ -61,6 +64,7 @@ ...@@ -61,6 +64,7 @@
} }
}, },
startCD() { startCD() {
clearInterval(this.timer);
this.timer = setInterval(() => { this.timer = setInterval(() => {
if (this.cd <= 0) { if (this.cd <= 0) {
clearInterval(this.timer); clearInterval(this.timer);
......
...@@ -11,6 +11,7 @@ if (process.env.NODE_ENV === 'development') { ...@@ -11,6 +11,7 @@ if (process.env.NODE_ENV === 'development') {
//API_HOST = '//localhost:3002'; //API_HOST = '//localhost:3002';
//API_HOST = window.__data.apiHost; //API_HOST = window.__data.apiHost;
//API_HOST = 'http://beacon.duiba.com.cn'; //API_HOST = 'http://beacon.duiba.com.cn';
//API_HOST = 'http://beacon.duibadev.com.cn';
} else { } else {
API_HOST = window.__data.apiHost; API_HOST = window.__data.apiHost;
} }
...@@ -19,7 +20,7 @@ if (API_HOST[API_HOST.length - 1] === '/') { ...@@ -19,7 +20,7 @@ if (API_HOST[API_HOST.length - 1] === '/') {
API_HOST = API_HOST.substr(0, API_HOST.length - 1); API_HOST = API_HOST.substr(0, API_HOST.length - 1);
} }
export const SSO_VERIFY_PAGE_URL = '/sso/logout'; export const SSO_VERIFY_PAGE_URL = '/sso/login';
export const DOCK_POINT_OFFSET = 4; export const DOCK_POINT_OFFSET = 4;
......
...@@ -55,9 +55,6 @@ ...@@ -55,9 +55,6 @@
return { return {
showFields: ['url', 'uuid'], showFields: ['url', 'uuid'],
currentItem: null, currentItem: null,
uploadHeaders: {
authorization: 'Bearer ' + window['zeroing_token'],
},
} }
}, },
computed: { computed: {
......
...@@ -88,9 +88,6 @@ ...@@ -88,9 +88,6 @@
children: 'children', children: 'children',
label: 'name' label: 'name'
}, },
uploadHeaders: {
authorization: 'Bearer ' + window['zeroing_token'],
},
expandedKeys: [], expandedKeys: [],
nodeFilterPresets: this.$t('nodeFilterPresets'), nodeFilterPresets: this.$t('nodeFilterPresets'),
iconMap: { iconMap: {
......
...@@ -203,7 +203,7 @@ ...@@ -203,7 +203,7 @@
name, name,
env, env,
isProd: true, isProd: true,
qas: [921], qas: [2085],
}; };
const {ret} = await playWaiting(saveSkin(params), this.$t('In processing')); const {ret} = await playWaiting(saveSkin(params), this.$t('In processing'));
if (ret.success !== false) { if (ret.success !== false) {
......
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