Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Syncs Latest Identification changes with determination history #2215

Open
wants to merge 1 commit into
base: Development
Choose a base branch
from

Conversation

mickley
Copy link
Collaborator

@mickley mickley commented Feb 12, 2025

The main occurrence editor has a Latest Identification section that shows the scientific name and associated information for an occurrence. This information is often also in the determination history. Symbiota has made strides in the last year on syncing this information between those two places. For example, when the current determination in the determination history is edited, that change is propagated to the Latest Identification section in the main editor, and when new records are added, their Latest Identification is automatically added to determination history.

However, when edits to the Latest Identification section occur on existing records, those changes were not being synced to the determination history, and the Current Determination in the determination history would show the old data. We've found this behavior to be very non-intuitive for users.

This PR updates the determination history for existing records when the Latest Identification section is edited

  • For records with no information in the Latest Identification section, adding information will trigger adding a corresponding entry in the determination history (previously, the determination history would remain empty)
  • For records with existing information in the Latest Identification section, editing that information will update the corresponding Current Determination entry in the determination history.

Pull Request Checklist:

Pre-Approval

  • There is a description section in the pull request that details what the proposed changes do. It can be very brief if need be, but it ought to exist.
  • Hotfixes should be branched off of the master branch and PR'd using the merge option (not squashed) into the hotfix branch.
  • Features and backlog bugs should be merged into the Development branch, NOT master
  • All new text is preferably internationalized (i.e., no end-user-visible text is hard-coded on the PHP pages), and the spreadsheet tracking internationalizations has been updated either with a new row or with checkmarks to existing rows.
  • There are no linter errors
  • New features have responsive design (i.e., look aesthetically pleasing both full screen and with small or mobile screens)
  • Symbiota coding standards have been followed
  • If any files have been reformatted (e.g., by an autoformatter), the reformat is its own, separate commit in the PR
  • Comment which GitHub issue(s), if any does this PR address
  • If this PR makes any changes that would require additional configuration of any Symbiota portals outside of the files tracked in this repository, make sure that those changes are detailed in this document.

Post-Approval

  • It is the code author's responsibility to merge their own pull request after it has been approved
  • If this PR represents a merge into the Development branch, remember to use the squash & merge option
  • If this PR represents a merge into the hotfix branch, remember to use the merge option (i.e., no squash).
  • If this PR represents a merge from the Development branch into the master branch, remember to use the merge option
  • If this PR represents a merge from the hotfix branch into the master branch use the squash & merge option
    • a subsequent PR from master into Development should be made with the merge option (i.e., no squash).
    • Immediately delete the hotfix branch and create a new hotfix branch
    • increment the Symbiota version number in the symbase.php file and commit to the hotfix branch.
  • If the dev team has agreed that this PR represents the last PR going into the Development branch before a tagged release (i.e., before an imminent merge into the master branch), make sure to notify the team and lock the Development branch to prevent accidental merges while QA takes place. Follow the release protocol here.
  • Don't forget to delete your feature branch upon merge. Ignore this step as required.

Thanks for contributing and keeping it clean!

…ith determination history.

For existing records, when the latest identification is changed, the corresponding entry (current determination) in the determination history is updated. When no determination history exists and the latest identification section is empty, any additions are also added to the determination history.
@themerekat themerekat requested a review from egbot February 12, 2025 19:24
@themerekat
Copy link
Collaborator

@mickley , we have plans to completely retire the taxonomic data in omoccurrences (in deference for just referencing omoccurdeterminations) in the future, but this keeps getting pushed down the line. Thanks for offering up this interim solution! I'll see if we can include it in a future release.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants