diff options
author | guochuyicmri <guochuyi@chinamobile.com> | 2019-04-03 15:17:50 +0800 |
---|---|---|
committer | guochuyicmri <guochuyi@chinamobile.com> | 2019-04-03 15:52:47 +0800 |
commit | 5cfce4879635df7cfc58a234277900470b536174 (patch) | |
tree | efdbed1f171417c3d660d4030517a5c5e63b379c | |
parent | d9a2d92a8bf316f2e6a3870c07caf304d65d978b (diff) |
Add backend Code for customer/serviceType management UI page
Change-Id: I008365b50908a1347e9b74e3c64673087a25df36
Issue-ID: USECASEUI-213
Signed-off-by: guochuyicmri <guochuyi@chinamobile.com>
3 files changed, 11 insertions, 3 deletions
diff --git a/server/src/main/java/org/onap/usecaseui/server/service/lcm/domain/aai/bean/AAIServiceSubscription.java b/server/src/main/java/org/onap/usecaseui/server/service/lcm/domain/aai/bean/AAIServiceSubscription.java index 2218cff3..8944816f 100644 --- a/server/src/main/java/org/onap/usecaseui/server/service/lcm/domain/aai/bean/AAIServiceSubscription.java +++ b/server/src/main/java/org/onap/usecaseui/server/service/lcm/domain/aai/bean/AAIServiceSubscription.java @@ -23,14 +23,22 @@ import com.fasterxml.jackson.annotation.JsonProperty; public class AAIServiceSubscription { private String serviceType; + + private String resourceVersion; @JsonCreator - public AAIServiceSubscription(@JsonProperty("service-type") String serviceType) { + public AAIServiceSubscription(@JsonProperty("service-type") String serviceType,@JsonProperty("resource-version") String resourceVersion) { this.serviceType = serviceType; + this.resourceVersion = resourceVersion; } @JsonProperty("service-type") public String getServiceType() { return serviceType; } + + @JsonProperty("resource-version") + public String getResourceVersion() { + return resourceVersion; + } } diff --git a/server/src/test/java/org/onap/usecaseui/server/service/lcm/domain/aai/bean/AAIServiceSubscriptionTest.java b/server/src/test/java/org/onap/usecaseui/server/service/lcm/domain/aai/bean/AAIServiceSubscriptionTest.java index 6082cba3..ff8bc240 100644 --- a/server/src/test/java/org/onap/usecaseui/server/service/lcm/domain/aai/bean/AAIServiceSubscriptionTest.java +++ b/server/src/test/java/org/onap/usecaseui/server/service/lcm/domain/aai/bean/AAIServiceSubscriptionTest.java @@ -52,7 +52,7 @@ public class AAIServiceSubscriptionTest { @Test public void testAAIServiceSubscription() throws Exception { - AAIServiceSubscription ass = new AAIServiceSubscription("serviceType"); + AAIServiceSubscription ass = new AAIServiceSubscription("serviceType","resourceVersion"); ass.getServiceType(); } } diff --git a/server/src/test/java/org/onap/usecaseui/server/service/lcm/impl/DefaultCustomerServiceTest.java b/server/src/test/java/org/onap/usecaseui/server/service/lcm/impl/DefaultCustomerServiceTest.java index 6ba2fa35..83c19fa0 100644 --- a/server/src/test/java/org/onap/usecaseui/server/service/lcm/impl/DefaultCustomerServiceTest.java +++ b/server/src/test/java/org/onap/usecaseui/server/service/lcm/impl/DefaultCustomerServiceTest.java @@ -76,7 +76,7 @@ public class DefaultCustomerServiceTest { @Test public void itCanRetrieveServiceSubscriptionsFromAAI() { - List<AAIServiceSubscription> serviceSubscriptions = singletonList(new AAIServiceSubscription("service type")); + List<AAIServiceSubscription> serviceSubscriptions = singletonList(new AAIServiceSubscription("service type","resourceVersion")); AAIService aaiService = mock(AAIService.class); ServiceSubscriptionRsp rsp = new ServiceSubscriptionRsp(); |