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

Endorse: Backend changes to display endorsement next to the author of a post in a topic #25

Merged
merged 2 commits into from
Oct 9, 2024

Conversation

Victor-Crawshaw
Copy link

@Victor-Crawshaw Victor-Crawshaw commented Oct 9, 2024

What

Update the backend to display endorsement next to the author of a post in a topic. Appears on page refresh after upvoting.

Why

An endorsement from a instructor indicates that posts are worth reading and are accurate.

How

Added a field "showendorse" to the return getVoteStatusByPostIDs() in src/posts/votes.js.
Added this field to the postObj in src/topics/posts.
Also cleaned up the corresponding public/openapi/read/topic/topic_id.yaml schema, and made sure to account for asynchronous functions in src/api/posts.js.

Testing

See PR #26

Screenshots

image
image

resolves #22

@Victor-Crawshaw Victor-Crawshaw added enhancement New feature or request size: m US2: endorse posts Features/changes related to the endorse posts element labels Oct 9, 2024
@Victor-Crawshaw Victor-Crawshaw self-assigned this Oct 9, 2024
@Victor-Crawshaw Victor-Crawshaw added the Endorse features/changes related to admins endorsing a post label Oct 9, 2024
@Victor-Crawshaw Victor-Crawshaw added this to the Sprint 2 milestone Oct 9, 2024
Copy link

@John-Crawshaw John-Crawshaw left a comment

Choose a reason for hiding this comment

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

These changes look good

@John-Crawshaw John-Crawshaw merged commit f8fc584 into f24 Oct 9, 2024
1 check passed
@coveralls
Copy link

Pull Request Test Coverage Report for Build 11261562795

Details

  • 11 of 11 (100.0%) changed or added relevant lines in 3 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage increased (+0.008%) to 82.67%

Totals Coverage Status
Change from base Build 11022516650: 0.008%
Covered Lines: 22335
Relevant Lines: 25596

💛 - Coveralls

@Victor-Crawshaw Victor-Crawshaw changed the title Backend changes to display endorsement next to the author of a post in a topic Endorse: Backend changes to display endorsement next to the author of a post in a topic Oct 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Endorse features/changes related to admins endorsing a post enhancement New feature or request size: m US2: endorse posts Features/changes related to the endorse posts element
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Endorse: Add endorsement message next to timestamp of post
3 participants