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

Feature/duplicating testimonia #456

Merged
merged 26 commits into from
Jun 18, 2024
Merged

Conversation

acholyn
Copy link
Collaborator

@acholyn acholyn commented Jun 3, 2024

closes #450

@acholyn acholyn marked this pull request as ready for review June 4, 2024 09:47
@acholyn acholyn requested a review from tcouch June 4, 2024 09:47
Copy link
Collaborator

@tcouch tcouch left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good except for missing duplicates section on Testimonium detail page. Also delete button seems not to work, but I guess that's a different PR.

src/rard/templates/research/testimonium_detail.html Outdated Show resolved Hide resolved
else:
# otherwise delete it from the anonfrag being converted
source.duplicate_afs.remove(d)
def transfer_duplicates(source, destination):
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Updated in recent commit to ensure destination is added as duplicate of the source's duplicate as well as the reverse relationship being created.

blank=True,
related_name="%(class)s_duplicate_ts",
)

@property
def duplicates_list(self):
duplicates = list(self.duplicate_frags.all())
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've simplified this in the latest commit: as long as we make sure duplicate relationships are always bi-directional, we shouldn't have to look at the reverse relationships.

@acholyn
Copy link
Collaborator Author

acholyn commented Jun 14, 2024

Looks good except for missing duplicates section on Testimonium detail page. Also delete button seems not to work, but I guess that's a different PR.

think it's in #442 (re button)
have also opened a new one specifically for this since 442 automatically merged with this PR

@acholyn acholyn merged commit 143be32 into development Jun 18, 2024
5 checks passed
@acholyn acholyn deleted the feature/duplicating-testimonia branch June 18, 2024 08:57
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.

Duplicating testimonia
2 participants