App-mgt store impl refactoring

feature/appm-store/pbac
amalhub 7 years ago
parent ee76f6cb0f
commit f4a3eb4601

@ -45,7 +45,7 @@ public class SubscriptionManagementAPIImpl implements SubscriptionManagementAPI{
@Override @Override
public Response installApplication(@ApiParam(name = "installationDetails", value = "The application ID and list" + public Response installApplication(@ApiParam(name = "installationDetails", value = "The application ID and list" +
" the devices/users/roles", required = true) @Valid InstallationDetails installationDetails) { " the devices/users/roles", required = true) @Valid InstallationDetails installationDetails) {
Object response = null; Object response;
SubscriptionManager subscriptionManager = APIUtil.getSubscriptionManager(); SubscriptionManager subscriptionManager = APIUtil.getSubscriptionManager();
try { try {
String applicationUUTD = installationDetails.getApplicationUUID(); String applicationUUTD = installationDetails.getApplicationUUID();
@ -60,6 +60,7 @@ public class SubscriptionManagementAPIImpl implements SubscriptionManagementAPI{
response = subscriptionManager.installApplicationForRoles(applicationUUTD, roleList); response = subscriptionManager.installApplicationForRoles(applicationUUTD, roleList);
} else { } else {
response = "Missing request data!"; response = "Missing request data!";
return Response.status(Response.Status.BAD_REQUEST).entity(response).build();
} }
return Response.status(Response.Status.OK).entity(response).build(); return Response.status(Response.Status.OK).entity(response).build();
} catch (ApplicationManagementException e) { } catch (ApplicationManagementException e) {

Loading…
Cancel
Save