Open rixx opened 4 months ago
@rixx can I take this up?
@mridubhatnagar sure!
@rixx I have completed the task.
Should I delete the file choices.py
as it is no more being used. Or we will be keeping it as is?
@rixx thanks for your inputs. Based on your inputs have updated the changes that I had done in questions.py. However, for submissions.py. Inheriting the class from TextChoices instead of Choices is leading to changes at other places in the codebase. Hence, I am still figuring it out.
As, the class is inheriting from TextChoices. I am not able to access the dictionaries present in SubmissionStates class from outside.
@mridubhatnagar I'm afriad I do not currently have the time to advise you in detail on how to implement this PR (if I had to do that, I might as well implement it myself in the same time). I think the choices going forward are that either this PR finishes the removal of pretalx.common.models.Choices
, or we'll close it for now.
@rixx you can close the MR.
Our helper class for enums/choices is used in only two places, and is from a time before Django had
TextChoices
, which we should use instead.