-
Notifications
You must be signed in to change notification settings - Fork 354
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: AuditType failing enum conversion when get tracked entity audits…
… [DHIS2-15805] [ 2.40 ] (#16102) * fix: failing enum conversion * fix: make tracked entity audit always insert audit type upper case
- Loading branch information
1 parent
df57d3a
commit 166191a
Showing
4 changed files
with
87 additions
and
34 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
25 changes: 25 additions & 0 deletions
25
...resources/org/hisp/dhis/db/migration/2.40/V2_40_28__Fix_Audit_Type_Case_Sensitive.sql.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
drop table if exists metadataaudit; | ||
|
||
update trackedentityinstanceaudit set audittype = 'CREATE' where audittype = 'create'; | ||
update trackedentityinstanceaudit set audittype = 'UPDATE' where audittype = 'update'; | ||
update trackedentityinstanceaudit set audittype = 'DELETE' where audittype = 'delete'; | ||
update trackedentityinstanceaudit set audittype = 'READ' where audittype = 'read'; | ||
update trackedentityinstanceaudit set audittype = 'SEARCH' where audittype = 'search'; | ||
|
||
update datavalueaudit set audittype = 'CREATE' where audittype = 'create'; | ||
update datavalueaudit set audittype = 'UPDATE' where audittype = 'update'; | ||
update datavalueaudit set audittype = 'DELETE' where audittype = 'delete'; | ||
update datavalueaudit set audittype = 'READ' where audittype = 'read'; | ||
update datavalueaudit set audittype = 'SEARCH' where audittype = 'search'; | ||
|
||
update trackedentityattributevalueaudit set audittype = 'CREATE' where audittype = 'create'; | ||
update trackedentityattributevalueaudit set audittype = 'UPDATE' where audittype = 'update'; | ||
update trackedentityattributevalueaudit set audittype = 'DELETE' where audittype = 'delete'; | ||
update trackedentityattributevalueaudit set audittype = 'READ' where audittype = 'read'; | ||
update trackedentityattributevalueaudit set audittype = 'SEARCH' where audittype = 'search'; | ||
|
||
update trackedentitydatavalueaudit set audittype = 'CREATE' where audittype = 'create'; | ||
update trackedentitydatavalueaudit set audittype = 'UPDATE' where audittype = 'update'; | ||
update trackedentitydatavalueaudit set audittype = 'DELETE' where audittype = 'delete'; | ||
update trackedentitydatavalueaudit set audittype = 'READ' where audittype = 'read'; | ||
update trackedentitydatavalueaudit set audittype = 'SEARCH' where audittype = 'search'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters