From 47b3dc980db22a0d0a0f166b57d516a97935bb4c Mon Sep 17 00:00:00 2001 From: daveotengo <30934250+daveotengo@users.noreply.github.com> Date: Mon, 12 Feb 2024 17:36:26 +0000 Subject: [PATCH] Added @Audited Annotations to classes that require them and rearranged key value pairs in strings and captions class#12881 --- .../de/symeda/sormas/api/i18n/Captions.java | 10 +++++----- .../de/symeda/sormas/api/i18n/Strings.java | 20 +++++++++---------- .../sormas/api/task/TaskContextIndex.java | 6 ++++++ .../symeda/sormas/api/user/UserRoleDto.java | 3 ++- .../src/main/resources/strings.properties | 2 +- 5 files changed, 24 insertions(+), 17 deletions(-) diff --git a/sormas-api/src/main/java/de/symeda/sormas/api/i18n/Captions.java b/sormas-api/src/main/java/de/symeda/sormas/api/i18n/Captions.java index 75357deec80..03d0cd9507a 100644 --- a/sormas-api/src/main/java/de/symeda/sormas/api/i18n/Captions.java +++ b/sormas-api/src/main/java/de/symeda/sormas/api/i18n/Captions.java @@ -620,6 +620,7 @@ public interface Captions { String Configuration_LineListing = "Configuration.LineListing"; String Configuration_Outbreaks = "Configuration.Outbreaks"; String Configuration_PointsOfEntry = "Configuration.PointsOfEntry"; + String confirmPassword = "confirmPassword"; String Contact = "Contact"; String Contact_additionalDetails = "Contact.additionalDetails"; String Contact_ageAndBirthDate = "Contact.ageAndBirthDate"; @@ -816,6 +817,7 @@ public interface Captions { String countryArchivedCountries = "countryArchivedCountries"; String createSymptomJournalAccountButton = "createSymptomJournalAccountButton"; String creationDate = "creationDate"; + String currentPassword = "currentPassword"; String CustomizableEnum_hasDetails = "CustomizableEnum.hasDetails"; String CustomizableEnum_hasDetails_short = "CustomizableEnum.hasDetails.short"; String CustomizableEnumValue_caption = "CustomizableEnumValue.caption"; @@ -1750,6 +1752,7 @@ public interface Captions { String outbreakNormal = "outbreakNormal"; String outbreakOutbreak = "outbreakOutbreak"; String passportNumber = "passportNumber"; + String passwordStrength = "passwordStrength"; String PathogenTest = "PathogenTest"; String PathogenTest_cqValue = "PathogenTest.cqValue"; String PathogenTest_ctValueE = "PathogenTest.ctValueE"; @@ -2606,6 +2609,7 @@ public interface Captions { String treatmentOpenPrescription = "treatmentOpenPrescription"; String unassigned = "unassigned"; String unknown = "unknown"; + String updatePassword = "updatePassword"; String User = "User"; String User_active = "User.active"; String User_address = "User.address"; @@ -2622,16 +2626,12 @@ public interface Captions { String User_userEmail = "User.userEmail"; String User_userName = "User.userName"; String User_userRoles = "User.userRoles"; - String updatePassword = "updatePassword"; - String currentPassword = "currentPassword"; - String confirmPassword = "confirmPassword"; - String passwordStrength = "passwordStrength"; String User_uuid = "User.uuid"; + String userGeneratePassword = "userGeneratePassword"; String userMyUserId = "userMyUserId"; String userNewUser = "userNewUser"; String userResetPassword = "userResetPassword"; String userRestrictDiseases = "userRestrictDiseases"; - String userGeneratePassword = "userGeneratePassword"; String userRight = "userRight"; String UserRight_caption = "UserRight.caption"; String UserRight_description = "UserRight.description"; diff --git a/sormas-api/src/main/java/de/symeda/sormas/api/i18n/Strings.java b/sormas-api/src/main/java/de/symeda/sormas/api/i18n/Strings.java index d2dc16ed1d8..3e0339d657b 100644 --- a/sormas-api/src/main/java/de/symeda/sormas/api/i18n/Strings.java +++ b/sormas-api/src/main/java/de/symeda/sormas/api/i18n/Strings.java @@ -184,6 +184,8 @@ public interface Strings { String confirmationVaccinationStatusUpdate = "confirmationVaccinationStatusUpdate"; String confirmExternalMessageCorrectionThrough = "confirmExternalMessageCorrectionThrough"; String confirmNetworkDiagramTooManyContacts = "confirmNetworkDiagramTooManyContacts"; + String confirmPassword = "confirmPassword"; + String currentPassword = "currentPassword"; String date = "date"; String day = "day"; String DefaultPassword_newPassword = "DefaultPassword.newPassword"; @@ -444,6 +446,7 @@ public interface Strings { String headingcasesWithReferenceDefinitionFulfilled = "headingcasesWithReferenceDefinitionFulfilled"; String headingCaution = "headingCaution"; String headingChangeCaseDisease = "headingChangeCaseDisease"; + String headingChangePassword = "headingChangePassword"; String headingChangePathogenTestResult = "headingChangePathogenTestResult"; String headingClinicalMeasurements = "headingClinicalMeasurements"; String headingClinicalVisitsDeleted = "headingClinicalVisitsDeleted"; @@ -667,7 +670,6 @@ public interface Strings { String headingLineListingImport = "headingLineListingImport"; String headingLocation = "headingLocation"; String headingLoginFailed = "headingLoginFailed"; - String headingUpdatePasswordFailed = "headingUpdatePasswordFailed"; String headingMaternalHistory = "headingMaternalHistory"; String headingMedicalInformation = "headingMedicalInformation"; String headingMergeDuplicateEventParticipantSamePersonSameEvent = "headingMergeDuplicateEventParticipantSamePersonSameEvent"; @@ -709,10 +711,6 @@ public interface Strings { String headingPaperFormDates = "headingPaperFormDates"; String headingPathogenTestsDeleted = "headingPathogenTestsDeleted"; String headingPersonData = "headingPersonData"; - String currentPassword = "currentPassword"; - String updatePassword = "updatePassword"; - String confirmPassword = "confirmPassword"; - String passwordStrength = "passwordStrength"; String headingPersonInformation = "headingPersonInformation"; String headingPersonOccupation = "headingPersonOccupation"; String headingPickEventGroup = "headingPickEventGroup"; @@ -821,7 +819,7 @@ public interface Strings { String headingUpdatedPersonInformation = "headingUpdatedPersonInformation"; String headingUpdatedSampleInformation = "headingUpdatedSampleInformation"; String headingUpdatePassword = "headingUpdatePassword"; - String headingChangePassword = "headingChangePassword"; + String headingUpdatePasswordFailed = "headingUpdatePasswordFailed"; String headingUpdatePersonContactDetails = "headingUpdatePersonContactDetails"; String headingUploadSuccess = "headingUploadSuccess"; String headingUserData = "headingUserData"; @@ -1349,13 +1347,12 @@ public interface Strings { String messageLineListingDisabled = "messageLineListingDisabled"; String messageLineListingSaved = "messageLineListingSaved"; String messageLoginFailed = "messageLoginFailed"; - String messageNewPasswordDoesNotMatchFailed = "messageNewPasswordDoesNotMatchFailed"; - String messagePasswordFailed = "messagePasswordFailed"; - String messageNewPasswordFailed = "messageNewPasswordFailed"; String messageMissingCases = "messageMissingCases"; String messageMissingDateFilter = "messageMissingDateFilter"; String messageMissingEpiWeekFilter = "messageMissingEpiWeekFilter"; String messageMultipleSampleReports = "messageMultipleSampleReports"; + String messageNewPasswordDoesNotMatchFailed = "messageNewPasswordDoesNotMatchFailed"; + String messageNewPasswordFailed = "messageNewPasswordFailed"; String messageNoCaseFound = "messageNoCaseFound"; String messageNoCaseFoundToLinkImmunization = "messageNoCaseFoundToLinkImmunization"; String messageNoCasesSelected = "messageNoCasesSelected"; @@ -1392,8 +1389,9 @@ public interface Strings { String messageNoVisitsSelected = "messageNoVisitsSelected"; String messageOtherDeleteReasonNotFilled = "messageOtherDeleteReasonNotFilled"; String messageOutbreakSaved = "messageOutbreakSaved"; - String messagePasswordReset = "messagePasswordReset"; String messagePasswordChange = "messagePasswordChange"; + String messagePasswordFailed = "messagePasswordFailed"; + String messagePasswordReset = "messagePasswordReset"; String messagePasswordResetEmailLink = "messagePasswordResetEmailLink"; String messagePathogenTestSaved = "messagePathogenTestSaved"; String messagePathogenTestSavedShort = "messagePathogenTestSavedShort"; @@ -1563,6 +1561,7 @@ public interface Strings { String of = "of"; String on = "on"; String or = "or"; + String passwordStrength = "passwordStrength"; String pathogenTestDeletedDuringLabMessageConversion = "pathogenTestDeletedDuringLabMessageConversion"; String pleaseSpecify = "pleaseSpecify"; String populationDataByArea = "populationDataByArea"; @@ -1710,6 +1709,7 @@ public interface Strings { String unsavedChanges_warningMessage = "unsavedChanges.warningMessage"; String unsavedChanges_warningTitle = "unsavedChanges.warningTitle"; String until = "until"; + String updatePassword = "updatePassword"; String uuidOf = "uuidOf"; String warningDashboardMapTooManyMarkers = "warningDashboardMapTooManyMarkers"; String warningNetworkDiagramTooManyContacts = "warningNetworkDiagramTooManyContacts"; diff --git a/sormas-api/src/main/java/de/symeda/sormas/api/task/TaskContextIndex.java b/sormas-api/src/main/java/de/symeda/sormas/api/task/TaskContextIndex.java index 472f9818e80..c2ba77a921c 100644 --- a/sormas-api/src/main/java/de/symeda/sormas/api/task/TaskContextIndex.java +++ b/sormas-api/src/main/java/de/symeda/sormas/api/task/TaskContextIndex.java @@ -19,11 +19,17 @@ package de.symeda.sormas.api.task; +import de.symeda.sormas.api.audit.AuditIncludeProperty; +import de.symeda.sormas.api.audit.AuditedClass; + import java.io.Serializable; +@AuditedClass public class TaskContextIndex implements Serializable, Cloneable { + @AuditIncludeProperty private TaskContext taskContext; + @AuditIncludeProperty private String uuid; public TaskContextIndex() { diff --git a/sormas-api/src/main/java/de/symeda/sormas/api/user/UserRoleDto.java b/sormas-api/src/main/java/de/symeda/sormas/api/user/UserRoleDto.java index 8016b1f17db..5b7ff0cd2e2 100644 --- a/sormas-api/src/main/java/de/symeda/sormas/api/user/UserRoleDto.java +++ b/sormas-api/src/main/java/de/symeda/sormas/api/user/UserRoleDto.java @@ -30,13 +30,14 @@ import com.fasterxml.jackson.annotation.JsonIgnore; import de.symeda.sormas.api.EntityDto; +import de.symeda.sormas.api.audit.AuditedClass; import de.symeda.sormas.api.i18n.I18nProperties; import de.symeda.sormas.api.i18n.Strings; import de.symeda.sormas.api.i18n.Validations; import de.symeda.sormas.api.utils.DataHelper; import de.symeda.sormas.api.utils.FieldConstraints; import de.symeda.sormas.api.utils.ValidationException; - +@AuditedClass public class UserRoleDto extends EntityDto { private static final long serialVersionUID = -547459523041494446L; diff --git a/sormas-api/src/main/resources/strings.properties b/sormas-api/src/main/resources/strings.properties index f80fb84ba57..0367628edd7 100644 --- a/sormas-api/src/main/resources/strings.properties +++ b/sormas-api/src/main/resources/strings.properties @@ -640,7 +640,7 @@ headingPersonData = Person data currentPassword=Enter Current Password updatePassword=Enter new Password confirmPassword=Confirm new Password -+passwordStrength=Password strength +passwordStrength=Password strength headingPersonInformation = Person information headingPersonOccupation = Occupation & education headingPickEventGroup = Pick event group