...
|
...
|
@@ -66,6 +66,21 @@ const domains = { |
|
|
shop: 'http://192.168.102.211:30016'
|
|
|
};
|
|
|
|
|
|
const isProd = process.env.NODE_ENV === 'production';
|
|
|
const isTest = (process.env.NODE_ENV || '').indexOf('test') >= 0;
|
|
|
|
|
|
if (isTest) {
|
|
|
domains.erp = 'http://192.168.103.82:9098';
|
|
|
domains.platform = 'http://192.168.102.210:8088/platform';
|
|
|
domains.shop = 'http://192.168.102.211:30016';
|
|
|
}
|
|
|
|
|
|
if (isProd) {
|
|
|
domains.erp = 'http://gw.erp.yohoops.org';
|
|
|
domains.platform = 'http://api.platform.yohoops.org/platform';
|
|
|
domains.shop = 'http://shops.yohobuy.com';
|
|
|
}
|
|
|
|
|
|
_.each(domainApis, (apis, domainName) => {
|
|
|
_.each(apis, (url, api) => {
|
|
|
apis[api] = _.get(domains, domainName, '') + url;
|
...
|
...
|
|