Fixes Dmp upload issues
This commit is contained in:
parent
443f010335
commit
ec6b50dc22
|
@ -606,7 +606,20 @@ public class DataManagementPlanManager {
|
||||||
associatedProfiles.add(associatedProfile);
|
associatedProfiles.add(associatedProfile);
|
||||||
}
|
}
|
||||||
List< eu.eudat.models.data.dmp.Organisation > organisations = new ArrayList<>();
|
List< eu.eudat.models.data.dmp.Organisation > organisations = new ArrayList<>();
|
||||||
|
for(OrganisationImportModel org : dataManagementPlans.get(0).getOrganisationImportModels()) {
|
||||||
|
eu.eudat.models.data.dmp.Organisation organisation = new eu.eudat.models.data.dmp.Organisation();
|
||||||
|
organisation.setLabel(org.getOrganaisationNameImport());
|
||||||
|
organisation.setId(org.getOrganaisationReferenceImport());
|
||||||
|
organisations.add(organisation);
|
||||||
|
}
|
||||||
List<eu.eudat.models.data.dmp.Researcher> researchers = new LinkedList<>();
|
List<eu.eudat.models.data.dmp.Researcher> researchers = new LinkedList<>();
|
||||||
|
for(ResearcherImportModels res : dataManagementPlans.get(0).getResearchersImportModels()) {
|
||||||
|
eu.eudat.models.data.dmp.Researcher researcher = new eu.eudat.models.data.dmp.Researcher();
|
||||||
|
researcher.setLabel(res.getResearcherImportName());
|
||||||
|
researcher.setId(res.getResearcherImportReference());
|
||||||
|
researchers.add(researcher);
|
||||||
|
}
|
||||||
|
|
||||||
List<eu.eudat.models.data.userinfo.UserInfo> associatedUsers = new LinkedList<>();
|
List<eu.eudat.models.data.userinfo.UserInfo> associatedUsers = new LinkedList<>();
|
||||||
List<DynamicFieldWithValue> dynamicFields = new LinkedList<>();
|
List<DynamicFieldWithValue> dynamicFields = new LinkedList<>();
|
||||||
|
|
||||||
|
|
|
@ -8,6 +8,7 @@ public class OrganisationImportModel {
|
||||||
private String source;
|
private String source;
|
||||||
private String name;
|
private String name;
|
||||||
private String id;
|
private String id;
|
||||||
|
private String reference;
|
||||||
|
|
||||||
@XmlElement(name = "source")
|
@XmlElement(name = "source")
|
||||||
public String getOrganaisationSourceImport() {
|
public String getOrganaisationSourceImport() {
|
||||||
|
@ -32,4 +33,8 @@ public class OrganisationImportModel {
|
||||||
public void setOrganaisationIdImport(String id) {
|
public void setOrganaisationIdImport(String id) {
|
||||||
this.id = id;
|
this.id = id;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@XmlElement(name = "reference")
|
||||||
|
public String getOrganaisationReferenceImport() { return reference; }
|
||||||
|
public void setOrganaisationReferenceImport(String reference) { this.reference = reference; }
|
||||||
}
|
}
|
||||||
|
|
|
@ -9,36 +9,41 @@ public class ResearcherImportModels {
|
||||||
private String name;
|
private String name;
|
||||||
private String id;
|
private String id;
|
||||||
private int status;
|
private int status;
|
||||||
|
private String reference;
|
||||||
|
|
||||||
@XmlElement(name = "label")
|
@XmlElement(name = "label")
|
||||||
public String getLabel() {
|
public String getResearcherImportLabel() {
|
||||||
return label;
|
return label;
|
||||||
}
|
}
|
||||||
public void setLabel(String label) {
|
public void setResearcherImportLabel(String label) {
|
||||||
this.label = label;
|
this.label = label;
|
||||||
}
|
}
|
||||||
|
|
||||||
@XmlElement(name = "name")
|
@XmlElement(name = "name")
|
||||||
public String getName() {
|
public String getResearcherImportName() {
|
||||||
return name;
|
return name;
|
||||||
}
|
}
|
||||||
public void setName(String name) {
|
public void setResearcherImportName(String name) {
|
||||||
this.name = name;
|
this.name = name;
|
||||||
}
|
}
|
||||||
|
|
||||||
@XmlElement(name = "id")
|
@XmlElement(name = "id")
|
||||||
public String getId() {
|
public String getResearcherImportId() {
|
||||||
return id;
|
return id;
|
||||||
}
|
}
|
||||||
public void setId(String id) {
|
public void setResearcherImportId(String id) {
|
||||||
this.id = id;
|
this.id = id;
|
||||||
}
|
}
|
||||||
|
|
||||||
@XmlElement(name = "status")
|
@XmlElement(name = "status")
|
||||||
public int getStatus() {
|
public int getResearcherImportStatus() {
|
||||||
return status;
|
return status;
|
||||||
}
|
}
|
||||||
public void setStatus(int status) {
|
public void setResearcherImportStatus(int status) {
|
||||||
this.status = status;
|
this.status = status;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@XmlElement(name = "reference")
|
||||||
|
public String getResearcherImportReference() { return reference; }
|
||||||
|
public void setResearcherImportReference(String reference) { this.reference = reference; }
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue