1
|
'use strict';
|
1
|
'use strict';
|
2
|
|
2
|
|
3
|
-const platformApi = new global.yoho.ApiBase(config.domains.platformApi, {
|
3
|
+const platformApi = new global.yoho.ApiBase(global.yoho.config.domains.platformApi, {
|
4
|
name: 'imCs',
|
4
|
name: 'imCs',
|
5
|
cache: global.yoho.cache,
|
5
|
cache: global.yoho.cache,
|
6
|
useCache: false
|
6
|
useCache: false
|
|
@@ -8,7 +8,7 @@ const platformApi = new global.yoho.ApiBase(config.domains.platformApi, { |
|
@@ -8,7 +8,7 @@ const platformApi = new global.yoho.ApiBase(config.domains.platformApi, { |
8
|
const api = global.yoho.API;
|
8
|
const api = global.yoho.API;
|
9
|
|
9
|
|
10
|
const index = (req) => {
|
10
|
const index = (req) => {
|
11
|
- return api.get('/platform/product/material/canlogin', { uid: req.user.uid }).then(data => {
|
11
|
+ return platformApi.get('/platform/product/material/canlogin', { uid: req.user.uid }).then(data => {
|
12
|
console.log(data);
|
12
|
console.log(data);
|
13
|
let params = {
|
13
|
let params = {
|
14
|
brandId: 1,
|
14
|
brandId: 1,
|
|
@@ -17,7 +17,7 @@ const index = (req) => { |
|
@@ -17,7 +17,7 @@ const index = (req) => { |
17
|
page: 1
|
17
|
page: 1
|
18
|
};
|
18
|
};
|
19
|
|
19
|
|
20
|
- return api.get('/platform/product/material/getList', Object.assign({
|
20
|
+ return platformApi.get('/platform/product/material/getList', Object.assign({
|
21
|
method: ''
|
21
|
method: ''
|
22
|
}, params), { cache: true });
|
22
|
}, params), { cache: true });
|
23
|
});
|
23
|
});
|