Skip to content

FC-0057: implement comment APIs#52

Merged
Faraz32123 merged 10 commits intomasterfrom
feat/implement_comment_apis
Aug 21, 2024
Merged

FC-0057: implement comment APIs#52
Faraz32123 merged 10 commits intomasterfrom
feat/implement_comment_apis

Conversation

@Faraz32123
Copy link
Copy Markdown
Contributor

@Faraz32123 Faraz32123 commented Aug 19, 2024

These below calls are implemented:

/comments/:comment_id DELETE (deletes parent/child comment) 
/comments/:comment_id GET (get parent comment) 
/comments/:comment_id POST (created child comment)
/comments/:comment_id PUT (updates parent/child comment)

This API(get "#{APIPREFIX}/comments" do) isn't being used in frontend.
close #37

- these call are implemented:
    /comments/:comment_id DELETE (deletes parent/child comment)
    /comments/:comment_id GET (get parent comment)
    /comments/:comment_id POST (created child comment)
    /comments/:comment_id PUT (updates parent/child comment)
@Faraz32123 Faraz32123 self-assigned this Aug 19, 2024
@Faraz32123 Faraz32123 changed the title feat: implement comment APIs FC-0057: implement comment APIs Aug 19, 2024
@Faraz32123 Faraz32123 marked this pull request as draft August 19, 2024 19:05
Muhammad Faraz Maqsood added 4 commits August 20, 2024 11:54
- handle child_count of parent comment in case of child comment deletion
- simplify code and use one serializer
- resolved quality checks
- fixed Comments models insert method definition
@Faraz32123 Faraz32123 requested review from Ali-Salman29 and taimoor-ahmed-1 and removed request for Ali-Salman29 August 20, 2024 11:56
@Faraz32123 Faraz32123 marked this pull request as ready for review August 20, 2024 11:56
@Faraz32123 Faraz32123 marked this pull request as draft August 20, 2024 12:07
@Faraz32123
Copy link
Copy Markdown
Contributor Author

Tests are failing after merging the code from master, i'll update my code accordingly to make tests pass and will turn the PR ready for review again.

@Faraz32123 Faraz32123 marked this pull request as ready for review August 20, 2024 12:14
Comment thread forum/models/comments.py Outdated
Comment thread forum/models/comments.py Outdated
Comment thread forum/models/comments.py Outdated
Comment thread forum/models/comments.py Outdated
Comment thread forum/serializers/comments_api.py Outdated
Comment thread forum/views/comments.py Outdated
Comment thread forum/views/comments.py Outdated
Comment thread forum/views/comments.py
Comment thread forum/views/comments.py Outdated
Comment thread forum/views/comments.py Outdated
- make changes to the previous comments serializers
- resolved comments
- fixed adding childs count if it was zero before
@Ali-Salman29
Copy link
Copy Markdown
Contributor

LGTM!

Copy link
Copy Markdown
Contributor

@taimoor-ahmed-1 taimoor-ahmed-1 left a comment

Choose a reason for hiding this comment

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

LGTM!

@Faraz32123 Faraz32123 merged commit a3d07f2 into master Aug 21, 2024
@Faraz32123 Faraz32123 deleted the feat/implement_comment_apis branch August 21, 2024 06:03
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.

Migrate the /comments API endpoints

3 participants