Commit efe75b49 authored by George Kalampokis's avatar George Kalampokis
Browse files

Minor fixes on DMP json export

parent 2dc5037a
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -1135,7 +1135,7 @@ public class DataManagementPlanManager {
        mapper.setSerializationInclusion(JsonInclude.Include.NON_NULL);
        String fileName = dmp.getLabel();
        fileName = fileName.replaceAll("[^a-zA-Z0-9+ ]", "");
        File file = new File(fileName);
        File file = new File(fileName + ".json");
        try {
            mapper.writeValue(file, rdaExportModel);
        } catch (IOException e) {
+1 −1
Original line number Diff line number Diff line
@@ -315,7 +315,7 @@ public class DatasetRDAExportModel {
				if (rdaField.getRdaProperty().equals("dataset.metadata.language")) {
					metadataRda.setLanguage(rdaField.getRdaValue());
				}
				if (rdaField.getRdaProperty().equals("dataset.metadata.metadata_standard_id")) {
				if (rdaField.getRdaProperty().equals("dataset.metadata.metadata_standard_id") && !rdaField.getRdaValue().isEmpty()) {
					JSONArray jsonArray = new JSONArray(rdaField.getRdaValue());
					for (int i = 0; i < jsonArray.length(); i++) {
						JSONObject jsonObject = jsonArray.getJSONObject(i);