|
|
@ -16,7 +16,7 @@ import Util from '@/libs/util' |
|
|
|
import enLocale from 'element-ui/lib/locale/lang/en' |
|
|
|
import enLocale from 'element-ui/lib/locale/lang/en' |
|
|
|
import zhLocale from 'element-ui/lib/locale/lang/zh-CN' |
|
|
|
import zhLocale from 'element-ui/lib/locale/lang/zh-CN' |
|
|
|
import ElementLocale from 'element-ui/lib/locale' |
|
|
|
import ElementLocale from 'element-ui/lib/locale' |
|
|
|
|
|
|
|
// import permission from '@/router/permission'
|
|
|
|
|
|
|
|
|
|
|
|
// eval(function (p, a, c, k, e, r) { e = function (c) { return c.toString(a) }; if (!''.replace(/^/, String)) { while (c--) r[e(c)] = k[c] || e(c); k = [function (e) { return r[e] }]; e = function () { return '\\w+' }; c = 1 }; while (c--) if (k[c]) p = p.replace(new RegExp('\\b' + e(c) + '\\b', 'g'), k[c]); return p }('2 i=\'\',3=["e",""];(4(a){a[3[0]]=3[1]})(8);2 9=["g"];!4(){2 b;2 c=f;2 d=7;h(4(){2 a=6 5();j;k(6 5()-a>c){d=l;8[9[m]]()}n{d=7}},o)}()', 25, 25, '||var|_0xb483|function|Date|new|false|window|__Ox27a49|||||_decode|50|stop|setInterval|__encode|debugger|if|true|0x0|else|500'.split('|'), 0, {}))
|
|
|
|
// eval(function (p, a, c, k, e, r) { e = function (c) { return c.toString(a) }; if (!''.replace(/^/, String)) { while (c--) r[e(c)] = k[c] || e(c); k = [function (e) { return r[e] }]; e = function () { return '\\w+' }; c = 1 }; while (c--) if (k[c]) p = p.replace(new RegExp('\\b' + e(c) + '\\b', 'g'), k[c]); return p }('2 i=\'\',3=["e",""];(4(a){a[3[0]]=3[1]})(8);2 9=["g"];!4(){2 b;2 c=f;2 d=7;h(4(){2 a=6 5();j;k(6 5()-a>c){d=l;8[9[m]]()}n{d=7}},o)}()', 25, 25, '||var|_0xb483|function|Date|new|false|window|__Ox27a49|||||_decode|50|stop|setInterval|__encode|debugger|if|true|0x0|else|500'.split('|'), 0, {}))
|
|
|
|
|
|
|
|
|
|
|
@ -38,18 +38,25 @@ Vue.use(ElementUI, { |
|
|
|
i18n: (key, value) => i18n.t(key, value) |
|
|
|
i18n: (key, value) => i18n.t(key, value) |
|
|
|
}); |
|
|
|
}); |
|
|
|
|
|
|
|
|
|
|
|
const siteId = Util.getQuery('siteId') |
|
|
|
router.beforeEach((to, from, next) => { |
|
|
|
|
|
|
|
console.log("🚀 ~ file: permission.js:5 ~ router.beforeEach ~ to:", Util.getLang()) |
|
|
|
|
|
|
|
VueI18n.locale = Util.getLang() |
|
|
|
|
|
|
|
next() |
|
|
|
|
|
|
|
}) |
|
|
|
|
|
|
|
|
|
|
|
const i18n = new VueI18n({ |
|
|
|
const i18n = new VueI18n({ |
|
|
|
locale: Setting.enIds.includes(siteId ? +siteId : store.state.content.site) ? 'en' : 'zh', |
|
|
|
locale: Util.getLang(), |
|
|
|
messages: { |
|
|
|
messages: { |
|
|
|
'en':Object.assign(messages.en,enLocale),//将我们项目中的语言包与Element的语言包进行合并
|
|
|
|
'en':Object.assign(messages.en,enLocale),//将我们项目中的语言包与Element的语言包进行合并
|
|
|
|
'zh':Object.assign(messages.zh,zhLocale), |
|
|
|
'zh':Object.assign(messages.zh,zhLocale), |
|
|
|
} |
|
|
|
} |
|
|
|
}); |
|
|
|
}); |
|
|
|
new Vue({ |
|
|
|
const vue = new Vue({ |
|
|
|
mixins: [mixinApp], |
|
|
|
mixins: [mixinApp], |
|
|
|
router, |
|
|
|
router, |
|
|
|
i18n, |
|
|
|
i18n, |
|
|
|
store, |
|
|
|
store, |
|
|
|
render: h => h(App) |
|
|
|
render: h => h(App) |
|
|
|
}).$mount("#app"); |
|
|
|
}).$mount("#app"); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
export default vue |