Adds the property of last modified on Dmps and Datasets.
This commit is contained in:
parent
7388cb479b
commit
9d4c3fca60
|
@ -18,6 +18,7 @@ public class DataManagementPlanListingModel implements DataModel<DMP, DataManage
|
|||
private String project;
|
||||
private String profile;
|
||||
private Date creationTime;
|
||||
private Date modifiedTime;
|
||||
private String organisations;
|
||||
private int version;
|
||||
private int status;
|
||||
|
@ -27,7 +28,6 @@ public class DataManagementPlanListingModel implements DataModel<DMP, DataManage
|
|||
public String getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(String id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
@ -35,7 +35,6 @@ public class DataManagementPlanListingModel implements DataModel<DMP, DataManage
|
|||
public String getLabel() {
|
||||
return label;
|
||||
}
|
||||
|
||||
public void setLabel(String label) {
|
||||
this.label = label;
|
||||
}
|
||||
|
@ -43,7 +42,6 @@ public class DataManagementPlanListingModel implements DataModel<DMP, DataManage
|
|||
public String getProject() {
|
||||
return project;
|
||||
}
|
||||
|
||||
public void setProject(String project) {
|
||||
this.project = project;
|
||||
}
|
||||
|
@ -51,7 +49,6 @@ public class DataManagementPlanListingModel implements DataModel<DMP, DataManage
|
|||
public String getProfile() {
|
||||
return profile;
|
||||
}
|
||||
|
||||
public void setProfile(String profile) {
|
||||
this.profile = profile;
|
||||
}
|
||||
|
@ -59,15 +56,20 @@ public class DataManagementPlanListingModel implements DataModel<DMP, DataManage
|
|||
public Date getCreationTime() {
|
||||
return creationTime;
|
||||
}
|
||||
|
||||
public void setCreationTime(Date creationTime) {
|
||||
this.creationTime = creationTime;
|
||||
}
|
||||
|
||||
public Date getModifiedTime() {
|
||||
return modifiedTime;
|
||||
}
|
||||
public void setModifiedTime(Date modifiedTime) {
|
||||
this.modifiedTime = modifiedTime;
|
||||
}
|
||||
|
||||
public String getOrganisations() {
|
||||
return organisations;
|
||||
}
|
||||
|
||||
public void setOrganisations(String organisations) {
|
||||
this.organisations = organisations;
|
||||
}
|
||||
|
@ -75,7 +77,6 @@ public class DataManagementPlanListingModel implements DataModel<DMP, DataManage
|
|||
public int getVersion() {
|
||||
return version;
|
||||
}
|
||||
|
||||
public void setVersion(int version) {
|
||||
this.version = version;
|
||||
}
|
||||
|
@ -83,7 +84,6 @@ public class DataManagementPlanListingModel implements DataModel<DMP, DataManage
|
|||
public UUID getGroupId() {
|
||||
return groupId;
|
||||
}
|
||||
|
||||
public void setGroupId(UUID groupId) {
|
||||
this.groupId = groupId;
|
||||
}
|
||||
|
@ -91,7 +91,6 @@ public class DataManagementPlanListingModel implements DataModel<DMP, DataManage
|
|||
public List<DatasetUrlListing> getDatasets() {
|
||||
return datasets;
|
||||
}
|
||||
|
||||
public void setDatasets(List<DatasetUrlListing> datasets) {
|
||||
this.datasets = datasets;
|
||||
}
|
||||
|
@ -99,7 +98,6 @@ public class DataManagementPlanListingModel implements DataModel<DMP, DataManage
|
|||
public int getStatus() {
|
||||
return status;
|
||||
}
|
||||
|
||||
public void setStatus(int status) {
|
||||
this.status = status;
|
||||
}
|
||||
|
@ -119,12 +117,12 @@ public class DataManagementPlanListingModel implements DataModel<DMP, DataManage
|
|||
this.project = entity.getProject().getLabel();
|
||||
if (entity.getProfile() != null) this.profile = entity.getProfile().getLabel();
|
||||
this.creationTime = entity.getCreated();
|
||||
this.modifiedTime = entity.getModified();
|
||||
this.organisations = LabelBuilder.getLabel(entity.getOrganisations().stream().map(item -> new Organisation().fromDataModel(item)).collect(Collectors.toList()));
|
||||
this.datasets = entity.getDataset().stream().map(x-> new DatasetUrlListing().fromDataModel(x)).collect(Collectors.toList());
|
||||
return this;
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public DMP toDataModel() {
|
||||
return null;
|
||||
|
|
|
@ -22,6 +22,7 @@ public class DatasetListingModel implements DataModel<Dataset, DatasetListingMod
|
|||
private String services;
|
||||
private int status;
|
||||
private Date created;
|
||||
private Date modified;
|
||||
private String description;
|
||||
|
||||
public String getId() {
|
||||
|
@ -101,6 +102,13 @@ public class DatasetListingModel implements DataModel<Dataset, DatasetListingMod
|
|||
this.created = created;
|
||||
}
|
||||
|
||||
public Date getModified() {
|
||||
return modified;
|
||||
}
|
||||
public void setModified(Date modified) {
|
||||
this.modified = modified;
|
||||
}
|
||||
|
||||
public String getDescription() {
|
||||
return description;
|
||||
}
|
||||
|
@ -113,6 +121,7 @@ public class DatasetListingModel implements DataModel<Dataset, DatasetListingMod
|
|||
this.id = entity.getId().toString();
|
||||
this.label = entity.getLabel();
|
||||
this.created = entity.getCreated();
|
||||
this.modified = entity.getModified();
|
||||
this.project = entity.getDmp().getProject().getLabel();
|
||||
this.dmp = entity.getDmp() != null ? entity.getDmp().getLabel() : "";
|
||||
this.dmpId = entity.getDmp() != null ? entity.getDmp().getId().toString() : "";
|
||||
|
|
|
@ -11,4 +11,5 @@ export interface DatasetListingModel {
|
|||
description: String;
|
||||
status: Number;
|
||||
created: Date;
|
||||
modified: Date;
|
||||
}
|
||||
|
|
|
@ -7,6 +7,7 @@ export interface DmpListingModel {
|
|||
project: String;
|
||||
profile: String;
|
||||
creationTime: String;
|
||||
modifiedTime: String;
|
||||
organisations: String;
|
||||
groupId: string;
|
||||
version: number;
|
||||
|
|
Loading…
Reference in New Issue