Skip to content

Feature: added contacted and confirmed users endpoints for ads and li…#526

Open
bringuy wants to merge 4 commits intomainfrom
feature/create-contacted-confirmed-users
Open

Feature: added contacted and confirmed users endpoints for ads and li…#526
bringuy wants to merge 4 commits intomainfrom
feature/create-contacted-confirmed-users

Conversation

@bringuy
Copy link
Contributor

@bringuy bringuy commented Jul 13, 2021

…stings. Added roommate endpoints but they're commented out because there isn't a roommate viewSet and a roommateSerializer

…stings. Added roommate endpoints but don't work because there isn't a roommate viewSet and a roommateSerializer
@bringuy bringuy added medium priority Medium priority ticket high priority High priority ticket labels Jul 13, 2021
@bringuy bringuy requested a review from a team July 13, 2021 22:06
@bringuy bringuy added the do not merge Do not merge this branch label Jul 13, 2021
@bringuy
Copy link
Contributor Author

bringuy commented Jul 13, 2021

Maybe we should change this ticket to blocked then add another ticket to make the roommateViewSet and serializer

@trentstauff trentstauff removed the medium priority Medium priority ticket label Jul 13, 2021
@deandrebaker deandrebaker removed the high priority High priority ticket label Jul 13, 2021
Copy link
Contributor

@deandrebaker deandrebaker left a comment

Choose a reason for hiding this comment

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

@luyaojchen @bringuy PR is looking good! I added some small requested changes for the names of some classes and for some copy-pasted comments.

I think you should finish implementing the serializers and model view set for roommate posts. It should be very straight forward. You can follow a very similar approach taken for listings.

Also, we can get rid of the AbstractLikedUsers class and replace all usages with the AbstractRetrieveUsers class.

@deandrebaker
Copy link
Contributor

Maybe we should change this ticket to blocked then add another ticket to make the roommateViewSet and serializer

I think you can make the missing components for the roommate posts endpoint. Just follow the same pattern used for listings.

@deandrebaker deandrebaker reopened this Jul 14, 2021
@deandrebaker
Copy link
Contributor

Whoops, I closed the PR by accident :3
I've reopened it.

@bringuy bringuy added high priority High priority ticket medium Medium difficulty level ready to merge This branch is able to be merged once approved and removed do not merge Do not merge this branch labels Jul 20, 2021
Comment on lines +60 to +69
@method_decorator(name="get", decorator=swagger_auto_schema(tags=["Ads"]))
class AdContacted(AbstractRetrieveUsers):
model_class = Ad
query_string = "contacted_users"


@method_decorator(name="get", decorator=swagger_auto_schema(tags=["Ads"]))
class AdConfirmed(AbstractRetrieveUsers):
model_class = Ad
query_string = "confirmed_users"
Copy link
Contributor

Choose a reason for hiding this comment

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

I also forgot to say to rename these too. My bad.

path("roommate/<int:id>/contacted", RoommatePostContactedUsers.as_view()),
path("roommate/<int:id>/confirmed", RoommatePostConfirmedUsers.as_view()),
]

Copy link
Contributor

Choose a reason for hiding this comment

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

Remove this new line

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

high priority High priority ticket medium Medium difficulty level ready to merge This branch is able to be merged once approved

Projects

None yet

Development

Successfully merging this pull request may close these issues.

API: Create contacted/confirmed users endpoints for ads, listings, and roommate posts

4 participants