Retrieve extra details

fix-try-it-meta-info
osh 1 year ago
parent 1d712e1bc2
commit 81e57ce78f

@ -1441,9 +1441,12 @@ public class GenericSubscriptionDAOImpl extends AbstractDAOImpl implements Subsc
try {
String sql = "SELECT "
+ "AP.NAME, "
+ "AP.TYPE, "
+ "AR.PACKAGE_NAME, "
+ "AR.VERSION, "
+ "DS.SUBSCRIBED_BY, "
+ "DS.STATUS "
+ "DS.STATUS, "
+ "DS.ACTION_TRIGGERED_FROM "
+ "FROM AP_APP_SUB_OP_MAPPING SOP "
+ "JOIN AP_DEVICE_SUBSCRIPTION DS ON SOP.AP_DEVICE_SUBSCRIPTION_ID = DS.ID "
+ "JOIN AP_APP_RELEASE AR ON DS.AP_APP_RELEASE_ID = AR.ID "

@ -380,9 +380,12 @@ public class DAOUtil {
while (rs.next()) {
Activity activity = new Activity();
activity.setAppName(rs.getString("NAME"));
activity.setAppType(rs.getString("TYPE"));
activity.setUsername(rs.getString("SUBSCRIBED_BY"));
activity.setPackageName(rs.getString("PACKAGE_NAME"));
activity.setStatus(rs.getString("STATUS"));
activity.setVersion(rs.getString("VERSION"));
activity.setTriggeredBy(rs.getString("ACTION_TRIGGERED_FROM"));
activities.add(activity);
}
return activities;

@ -174,6 +174,9 @@ public class ActivityProviderServiceImpl implements ActivityInfoProviderService
activity.setPackageName(appActivity.getPackageName());
activity.setAppName(appActivity.getAppName());
activity.setStatus(appActivity.getStatus());
activity.setAppType(appActivity.getAppType());
activity.setVersion(appActivity.getVersion());
activity.setTriggeredBy(appActivity.getTriggeredBy());
} else {
String msg = "Cannot find the app details related to the operation ";
log.error(msg);

@ -93,6 +93,18 @@ public class Activity {
value = "Status of app install")
private String status;
@ApiModelProperty(name = "version",
value = "Version of app")
private String version;
@ApiModelProperty(name = "triggeredBy",
value = "Operation triggered by what")
private String triggeredBy;
@ApiModelProperty(name = "appType",
value = "Type of application")
private String appType;
public String getActivityId() {
return activityId;
@ -173,5 +185,29 @@ public class Activity {
public void setStatus(String status) {
this.status = status;
}
public String getVersion() {
return version;
}
public void setVersion(String version) {
this.version = version;
}
public String getTriggeredBy() {
return triggeredBy;
}
public void setTriggeredBy(String triggeredBy) {
this.triggeredBy = triggeredBy;
}
public String getAppType() {
return appType;
}
public void setAppType(String appType) {
this.appType = appType;
}
}

Loading…
Cancel
Save