抽离登陆模块
This commit is contained in:
52
public/config.js
Normal file
52
public/config.js
Normal file
@@ -0,0 +1,52 @@
|
||||
export const silkyConfig = {
|
||||
captchaAppId: '196626989',
|
||||
wxLogin: {
|
||||
appid: 'wxea912643e8747b44',
|
||||
redirect_uri: 'https://kevisual.silkyai.cn/api/wx/login',
|
||||
},
|
||||
wxmpLogin: {
|
||||
loginUrl: `https://kevisual.xiongxiao.me/root/mini-web/login.html`,
|
||||
},
|
||||
loginWay: ['account', 'wechat', 'phone', 'wechat-mp'],
|
||||
loginSuccess: '/root/center/',
|
||||
loginSuccessIsNew: '/root/center/',
|
||||
beian: '浙ICP备2024137660号-1',
|
||||
};
|
||||
|
||||
const currentUrl = new URL(window.location.href);
|
||||
const redirect = currentUrl.origin + currentUrl.pathname;
|
||||
export const kevisualConfig = {
|
||||
loginWay: ['account', 'wechat'],
|
||||
loginSuccess: '/root/center/',
|
||||
loginSuccessIsNew: '/root/center/',
|
||||
wxLogin: {
|
||||
appid: 'wx9378885c8390e09b',
|
||||
redirect_uri: redirect,
|
||||
},
|
||||
beian: '浙ICP备2025158778号',
|
||||
logo: 'https://kevisual.xiongxiao.me/root/center/panda.png',
|
||||
logoStyle: {
|
||||
borderRadius: '50%',
|
||||
marginTop: '10px',
|
||||
margin: '30px auto',
|
||||
},
|
||||
};
|
||||
|
||||
const kevisualXiongxiaoConfig = {
|
||||
...kevisualConfig,
|
||||
loginWay: ['account', 'wechat-mp'],
|
||||
wxLogin: {
|
||||
appid: 'wxff97d569b1db16b6',
|
||||
redirect_uri: redirect,
|
||||
},
|
||||
wxmpLogin: {
|
||||
loginUrl: `${currentUrl.origin}/root/mini-web/login.html`,
|
||||
},
|
||||
logo: 'https://kevisual.xiongxiao.me/root/center/panda.png',
|
||||
beian: '蜀ICP备16031039号-2',
|
||||
};
|
||||
|
||||
const url = new URL(window.location.href);
|
||||
const isKevisual = url.hostname === 'kevisual.cn';
|
||||
const isKevisualXiongxiao = url.hostname === 'kevisual.xiongxiao.me';
|
||||
export const config = isKevisual ? kevisualConfig : isKevisualXiongxiao ? kevisualXiongxiaoConfig : silkyConfig;
|
||||
Reference in New Issue
Block a user