Page tree
Skip to end of metadata
Go to start of metadata
  1. The next step is to create the input controls that will be used to provide this cascading behaviour. The first input control to create is the Course Categories one. 
  2. When logged into Zoola, follow this URL ( to be taken to the Create Input Control workflow.

  3. In the Type field, select Multi-Select Query.
  4. In the Prompt Text field, enter "Course Categories".
  5. In the Parameter Name field, enter the Parameter ID for the Course Categories ID filter in your Report: "course_category_id_1".
  6. After the optional Description field, ensure that the Visible option is checked.
  7. Click the Next button. The Locate Query page appears:

  8. Select Define a Query in the next step, as you will be entering a new unique query instead of selecting an existing one.
  9. Click the Next button. The Name the Query page appears:

  10.  Enter "Course Categories" in the Name field (the Resource ID field will auto-populate).
  11.  Click the Next button. The Link a Data Source to the Query page appears:

  12. Select the Select data source from Repository option.
  13. Click Browse and identify the Totara data source (Public > Moodle/Totara > Data Connections > Totara), then click Select.
  14. Click Next. The Define the Query page appears:

  15. From the Query Language list, select SQL.
  16. In the Query String field, enter the following query:

    select id, name, concat(repeat(concat('&nbsp', char(59 using utf8)), (depth-1)*2), name) as hierarchy_name
    from mdl_course_categories
    order by sortorder
  17. click the Save button. The Save Parameters page appears:

  18. In the Value Column field, enter "id". This enables the Input Control window to present values based on the ID fields from the mdl_course_categories table.

  19. In the Visible Columns field, enter "name" and click the Add button. This enables the Input Control window to present the ID fields by their associated name. In this case, this will display the Course Categories by their proper names instead of their IDs.

  20. Click the Submit button.

Proceed to Creating the Cascading Courses Input Control.

  • No labels