From fa426eee7abcb1a509b263585f4556f661a99d38 Mon Sep 17 00:00:00 2001 From: cyuamber Date: Wed, 11 Sep 2019 17:19:46 +0800 Subject: feat: add post and put mock method Change-Id: Ibe85c6deacb9f38795f33a4379c33a891bb3ef28 Issue-ID: USECASEUI-306 Signed-off-by: cyuamber --- .../src/app/core/services/managemencs.service.ts | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) (limited to 'usecaseui-portal/src/app/core/services') diff --git a/usecaseui-portal/src/app/core/services/managemencs.service.ts b/usecaseui-portal/src/app/core/services/managemencs.service.ts index b7aff872..cd293d40 100644 --- a/usecaseui-portal/src/app/core/services/managemencs.service.ts +++ b/usecaseui-portal/src/app/core/services/managemencs.service.ts @@ -20,10 +20,11 @@ export class ManagemencsService { //mock Currently unadjustable api interface deleteCustomer: this.baseUrl + "/uui-lcm/customers", /* delete */ createCustomer: this.baseUrl + "/uui-lcm/customers/", /* put */ - createServiceType: this.baseUrl + "/uui-lcm/customers/*_*/service-subscriptions/*+*", /* put */ getCustomerresourceVersion: this.baseUrl + "/uui-lcm/customers/*_*", /* get */ - getServiceTypeResourceVersion: this.baseUrl + "/uui-lcm/customers/*_*/service-subscriptions/*+*", - deleteServiceType: this.baseUrl + "/uui-lcm/customers/*_*/service-subscriptions/*+*", + + createServiceType: this.baseUrl + "/uui-lcm/customers/*_*/service-subscriptions/*+*", /* put */ + getServiceTypeResourceVersion: this.baseUrl + "/uui-lcm/customers/*_*/service-subscriptions/*+*", /* get */ + deleteServiceType: this.baseUrl + "/uui-lcm/customers/*_*/service-subscriptions/*+*", /* delete */ }; //The following APIs are optimizable ---------------------------------- @@ -41,7 +42,7 @@ export class ManagemencsService { deleteSelectCustomer(paramsObj) { let url = this.url.deleteCustomer; let params = new HttpParams({ fromObject: paramsObj }); - return this.http.delete(url,{params}); + return this.http.delete(url, { params }); } //The following APIs are not optimizable --------------------------------- @@ -84,10 +85,10 @@ export class ManagemencsService { let customerId = paramsObj.customerId.id, ServiceType = paramsObj.ServiceType, version = { - "resourceVersion":paramsObj.version + "resourceVersion": paramsObj.version }; let url = this.url.deleteServiceType.replace("*_*", customerId).replace("*+*", ServiceType); let params = new HttpParams({ fromObject: version }); - return this.http.delete(url,{params}); + return this.http.delete(url, { params }); } } -- cgit 1.2.3-korg