Allow renewing and adding new users by number of terms #75
Labels
No Label
priority
high
priority
low
priority
medium
priority
very high
BUG
Feature
High Priority
Low Priority
Medium Priority
No Milestone
No project
No Assignees
4 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: public/pyceo#75
Loading…
Reference in New Issue
No description provided.
Delete Branch "%!s(<nil>)"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
In the CEO API, currently you have to specify exactly what terms to add in
/<username>/renew
and/members/
.It would be better, if there was an extra option (similar to the GUI), where in addition to "terms" and "non_member_terms", there also is "number_of_terms" and possibly "number_of_non_member" terms. These options would be integers and would renew/create member for that many number of terms.
It should be straightforward, since get_terms_for_new_user, get_terms_for_renewal already exist in https://git.csclub.uwaterloo.ca/public/pyceo/src/branch/master/ceo/term_utils.py#L11, and the API would have to modified here to use them https://git.csclub.uwaterloo.ca/public/pyceo/src/branch/master/ceod/api/members.py
Say if a user has terms
and current term is
f2022
should adding 1 term add
w2023
ors2021
?behaviuor of
get_terms_for_renewal
would bew2023
so I'll make it do that.side note:
get_terms_for_renewal
function is written for client so is not suitable for server side useNo, it would be
f2022
. See https://git.csclub.uwaterloo.ca/public/pyceo/src/branch/master/ceo/term_utils.py#L35.@r345liu thanks for taking this.
@snedadah can you confirm this removes one of the blockers on the membership webpage?
@r389li, Yep, once this is deployed, it will remove that blocker for the membership webpage.
Great! @r345liu can you package and deploy it?