"Polymorphic" UI for SchoolInspections

Issue #301 resolved
Brian Lewis repo owner created an issue

The Kobo / School Inspections interface (#297 ) supports "polymorphic" reads of school inspections that will decode any custom fields stored in the Xml Blob. Design a UI in the web interface to display a single inspection, in a UI customised for that inspections Inspection type. Also support searching through Inspections globally, as well as the current access of inspections for a single school.

Comments (3)

  1. Brian Lewis reporter

    This comes to attention again as part of handling of schoolaccreditations and Wash surveys imported from tablet.

    Polymorphism is handled in the schoolinspection component, by defining a template that in turn loads (via ng-include) another template based on the inspectionType.

    The same polymorphic Ui is used to display different “Form B” implementations, and different UI for Xml survey contents.

    These families of templates are held in specific folder locations -

    schoolinspection/inspectiontype : holds the UI for various schoolinspections, by type. Invoked from the schoolinspections item states.

    schoolinspection/survey : holds the UI for various survey Xml as collected by the tablet, and stored into inspXml on SchoolInspections. These are also named via inspectiontype, and are used in both schoolinspection and cloudfile Ui.

    schoolaccreditation/formb : Form B implementations. Used by cloudfiles, schoolaccreditations, schoolinspections.

    Note that the usual methods for creating context-specific versions of all these templates still apply. This is of aprticular importance for FormB for example.

  2. Log in to comment