Interface to add questions via website
Questions are added via the file system right now. We need a mechanism to be able to add them via the web interface.
roadmap for this:
- finish #117
- finish #118
- let anyone add questions. Each question has a "added by" field
- let anyone create contests by selecting questions. Each contest has a "host"
- Host has full control over contest settings like start/end time, title, questions to be included.
Can I work on this enhancement ?
sure sure. no need to ask please go ahead and open a PR :+1:
So when a user is going to upload the question, he will uploading three sets of files which are the input, output and statement. Now, the existing model for the questions are
class Question(Model):
q_no = IntegerField(unique=True)
author = ForeignKeyField(User)
class Meta:
database = db
Presently, the questions are being referenced from a folder. Should I continue with the same or use the database to store the entire contents of the file the user has uploaded ?
I'll say 2 files for I/o then one text field to capture statement.
Let's put everything in the database. Sqlite can handle up to 1tb easily