Commit dfeb1b65 by zhujian

fix

parent 62df917a
......@@ -13,8 +13,9 @@ import User from '@/common/js/user';
import Service from '@/common/js/service';
export default class WechatApi {
static async initConfig(params = { isAgentConfig: false, url: '' }) {
static initConfig(params = { isAgentConfig: false, url: '' }) {
if (Platform.isWorkWx()) {
return new Promise(async (resolve, reject) => {
Service.Hades('anon/hades/getWxCorpJSAPISignature', {
storeId: User.getStoreId(),
url: window.location.href.split('#')[0],
......@@ -58,7 +59,13 @@ export default class WechatApi {
wx.error((err) => {
console.log('getWxCorpJSAPISignature', err)
});
})
} else {
return new Promise(async (resolve, reject) => {
Service.Hades('anon/hades/getWxWorkJSAPISignature', {
storeId: User.getStoreId(),
url: window.location.href.split('#')[0],
......@@ -82,6 +89,7 @@ export default class WechatApi {
},
});
});
});
}
}
......
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