diff options
author | cyuamber <xuranyjy@chinamobile.com> | 2019-09-04 17:54:23 +0800 |
---|---|---|
committer | xu ran <xuranyjy@chinamobile.com> | 2019-09-04 13:37:55 +0000 |
commit | 16ea8b7de7d7a51d05c1890144f1799c7e41f8c7 (patch) | |
tree | ba009d3ebfd748f4f7c9ee71a43fc46ff97223c1 /usecaseui-portal/src | |
parent | ec06b7c5fbaba86c367b7ea6e6c4262e4e50596b (diff) |
feat:optimize the mock api of the home page
Change-Id: Ie569f729e23e232446fd3b8db05c41189c088d24
Issue-ID: USECASEUI-307
Signed-off-by: cyuamber <xuranyjy@chinamobile.com>
Diffstat (limited to 'usecaseui-portal/src')
-rw-r--r-- | usecaseui-portal/src/app/core/models/dataInterface.ts | 1 | ||||
-rw-r--r-- | usecaseui-portal/src/app/core/services/homes.service.ts | 16 | ||||
-rw-r--r-- | usecaseui-portal/src/app/mock/routes.js | 2 |
3 files changed, 4 insertions, 15 deletions
diff --git a/usecaseui-portal/src/app/core/models/dataInterface.ts b/usecaseui-portal/src/app/core/models/dataInterface.ts index e092bd03..012b23e6 100644 --- a/usecaseui-portal/src/app/core/models/dataInterface.ts +++ b/usecaseui-portal/src/app/core/models/dataInterface.ts @@ -1,6 +1,5 @@ enum baseUrl{ baseUrl = '/api/usecaseui-server/v1' //online - // baseUrl = 'http://172.19.44.223/api/usecaseui-server/v1' //local one // baseUrl = 'http://10.73.191.100:8082' //local two } interface homeData { diff --git a/usecaseui-portal/src/app/core/services/homes.service.ts b/usecaseui-portal/src/app/core/services/homes.service.ts index 218756d4..321642db 100644 --- a/usecaseui-portal/src/app/core/services/homes.service.ts +++ b/usecaseui-portal/src/app/core/services/homes.service.ts @@ -23,16 +23,13 @@ export class HomesService { constructor(private http: HttpClient) { } baseUrl = baseUrl.baseUrl; - baseUrlbar = baseUrl.baseUrl + "/uui-lcm/"; url = { home_serviceData: this.baseUrl + "/uui-lcm/serviceNumByCustomer", - home_performanceData: this.baseUrl + "/performance/queryAllSourceNames", home_alarmData: this.baseUrl + "/alarm/statusCount", home_alarmChartData: this.baseUrl + "/alarm/diagram", - home_servicebarData: this.baseUrl + "", - home_servicebarnsData: this.baseUrlbar + "ns-packages", - home_servicebarvnfData: this.baseUrlbar + "vnf-packages", - home_servicebarpnfData: this.baseUrlbar + "pnf-packages", + home_servicebarnsData: this.baseUrl + "/uui-lcm/ns-packages", + home_servicebarvnfData: this.baseUrl + "/uui-lcm/vnf-packages", + home_servicebarpnfData: this.baseUrl + "/uui-lcm/pnf-packages", sourceNames: this.baseUrl + "/alarm/getSourceNames", listSortMasters: this.baseUrl + "/listSortMasters", currentLanguage: "/api/portal-auxapi/languageSetting/user/", @@ -42,9 +39,6 @@ export class HomesService { getHomeServiceData() { return this.http.get<any>(this.url.home_serviceData); } - getHomePerformanceData() { - return this.http.get<String[]>(this.url.home_performanceData); - } getHomeAlarmData() { return this.http.get<any>(this.url.home_alarmData); } @@ -52,10 +46,6 @@ export class HomesService { let params = new HttpParams({ fromObject: paramsObj }); return this.http.get<any>(this.url.home_alarmChartData, { params }); } - - getHomeServiceBarData() { - return this.http.get<any>(this.url.home_servicebarData); - } getHomeServiceBarNsData() { return this.http.get<any>(this.url.home_servicebarnsData); } diff --git a/usecaseui-portal/src/app/mock/routes.js b/usecaseui-portal/src/app/mock/routes.js index 8d4485b8..9561436e 100644 --- a/usecaseui-portal/src/app/mock/routes.js +++ b/usecaseui-portal/src/app/mock/routes.js @@ -26,7 +26,7 @@ module.exports = /////////////// ///////<-------------home services--------->///// - "/usecaseui-server/v1/alarm/getSourceNames/": "/alarm_getSourceNames", + "/usecaseui-server/v1/alarm/getSourceNames": "/alarm_getSourceNames", "/portal-auxapi/languageSetting/user/:currentloginId": "/language", ///////////////////////// |