Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Closes #1511
Description
This pull request improves the
Notificationmodel in the CiviWiki codebase by addressing several issues related to readability, maintainability, and consistency. The key improvements include:activity_CHOICES: Hardcoded strings have been replaced with anEnum, ensuring consistency and reducing the risk of errors when modifying or using activity types.activity_CHOICESvalue"response_to_yout_civi", correcting it to"response_to_your_civi".blank=Trueandnull=True) from thecreatedandlast_modifiedfields, as these were unnecessary for fields usingauto_now_addandauto_now.ForeignKeyfields to improve clarity about their relationships.These changes make the codebase more maintainable, professional, and easier to work with, aligning with best practices in software engineering. The pull request also includes updated unit tests to ensure the correctness of the changes and compatibility with the existing system.