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

api/codeforces: Expose user submissions data (with DB persistence) #11

Open
KShivendu opened this issue Jul 24, 2021 · 1 comment
Open

Comments

@KShivendu
Copy link
Member

You may refer to what I've done for displaying rating_update data.

The steps that you need to take are :

  • models.py create new model CodeforcesUserSubmission which should be similar to CodeforcesUserRatingUpdate
  • serializers.py: Create a new serializer Cf_Submission_Serializer which should be similar to Cf_RatingUpdate_Serializer
  • serializer.py: add submissions variable in Cf_User_Serializer (similar to rating_updates)
  • views.py: Use code from self.submissions at line 162 and store the relevant data in CodeforcesUserSubmission model

You might have to modify the submissions() function to adjust for the new changes.

@akshaywairagade2
Copy link
Contributor

yes i will look into it

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

No branches or pull requests

2 participants