Skip to content

How to add new features

cjshawMIT edited this page Apr 28, 2017 · 1 revision

Introduction

Since qbank relies so heavily on dlkit, some features cannot be added without corresponding changes to the dlkit library. Here we try to describe what changes can be made directly to qbank and what requires dlkit changes. For all changes, we follow a branch and PR process via the git repositories.

qbank only changes

If you want to expose convenience methods or manipulate existing data without changing the underlying data schema, then you can make changes to the qbank code without touching dlkit. Some examples of this might be:

  • Providing an analytics endpoint that aggregates data across multiple banks or assessments.
  • Creating a single assessment authoring endpoint that also creates an assessmentOffered (turning a two-step process into a one-step process).
  • Querying for a single user's results across all assessments.
  • Adding UI access to existing dklit model fields, that currently aren't exposed RESTfully (like certain query parameters or asset fields).

qbank + dlkit changes

If you want to change the model / schema, then you need to change dlkit itself. Furthermore, whenever you change dlkit and want that functionality exposed to the UI, you will need to add some qbank code that translates between the UI and dlkit. Generally this is done via dlkit forms, and you can find many examples in the code base. Some things that would require you to change dlkit and qbank in conjunction are:

  • Adding new question types.
  • Adding new parameters to existing question types (i.e. adding a set of label options to multiple choice, so authors can specify if the choices appear with 1, 2, 3 or a, b, c).
  • Adding new behavior to existing parameters (i.e. making asset license multi-language).
  • Adding auto-evaluation to question types, like short-answer.