Skip to content

Staff Dashboard

blackening edited this page May 1, 2021 · 8 revisions

AY1920 Semester 2 CP3108: Staff Dashboard (cadet frontend)

The aim of the Staff Dashboard project is to make the administrative workflow easier for the staff over the course of a semester.

The three main components of the Staff Dashboard Project are:

Avengers Leaderboard

The Source Academy does not have way for staff to keep track of each avenger's grading progress and this is a very important information for staffs to know over the course of a semester as it allows for staffs to intervene should any Avenger fall behind in terms of grading.

Pull Requests

Changelog

  • Added a HTTP GET route to /groups that returns the overviews of each group in the course. The overview contains the id of the group, the group name and the name of the group's Avenger.
  • Added a corresponding GroupController to handle the aforementioned GET request.

Assessment Uploader

The previous workflow for uploading assessments was very inconvenient, as feedbacked by the professors. The workflow involved uploading the assessment files to a bitbucket repository and the backend only pulls from this repository every hour. This means that assessments cannot be uploaded immediately to the Source Academy. On top of that, once assessments are open, they cannot be changed, not even a minor typo fix can be done without directly accessing the database.

As such, the Assessment Uploader also called the Ground Control provides a UI where the staffs can upload the assessment files anytime they want and it will be immediately parsed and uploaded into the backend database. The Ground Control allows for staffs to make changes (with certain constraints) to assessments that are already open. Staffs can also choose to delete or to publish/unpublish uploaded assessments. Published assessments will be viewable by both staffs and students while unpublished assessments are only viewable by staffs.

Pull Requests

Changelogs

  • Added various routes to handle the uploading/deleting/editing of assessments:
    • DELETE /assessments/:id
    • POST /assessments
    • POST /assessments/publish/:id
    • POST /assessments/update/:id
  • Allows for updating of assessments by reuploading the assessment XML file. Only force updating would be allowed if the assessment is opened already.
  • Modified and added various methods in xml_parserand in assessments to handle the additional routes. The 'parse_xml' method now returns the error message if there is any error in parsing. This is done to allow the frontend to receive the error message.
  • Modified how the is_published field for assessments work. When an assessment is unpublished, instead of being unviewable by all users, staffs and admins will now be able to view unpublished assessments.
  • Assessments have the 'is_published' field set to false by default when it is parsed.
  • Changed the all_published_assessments in cadet/assessments/assessments.ex to all_assessments. Returns all assessments/all published assessments depending on the role of the user.
  • Added isPublished field to assessments_view.
  • XML files for assessments no longer require the 'startdate' and 'enddate' tags. The assessments will now have a default start date at 12pm three days after the day the assessment is uploaded at and the default close date is one week after the default start date.
  • Existing tests have been modified to accommodate the modifications made.

Playground Default Source Version Selector

The Playground Default Source Version Selector allows staff/admin to change the default source version of the playground as the semester progresses.

Pull Requests

Changelog

  • Added routes to handle the getting/updating of the default source version:
    • GET /chapter
    • POST /chapter/update/:id
  • Added a corresponding ChaptersController.
  • Created migration Cadet.Repo.Migrations.CreateChaptersTable and updated seed.