Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Show two options for items in folder array [SA-18729] master #165

Open
wants to merge 6 commits into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
47 changes: 28 additions & 19 deletions openapi/paths/assessment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,12 @@ parameters:
in: query
required: true
description: |
Json encoded object of fields and values to filter assessments on. \
JSON encoded object of fields and values to filter assessments on. \
For example, to get assessment with ID 676: \
`filter=%7b%22assessmentId%22%3a676%7d`

Filter string to filter on all the fields would look like: \
`{"assessmentId": 256,"title": "English 3/4 [Final]","assessmentType": "dueWork","folder": {id: 80},"weighted": false,"workType": {"id": 1,"name": "Formative Assessment"},"dueDate": {"from": "2017-10-12T14:20:50+10:00","to": "2019-10-12T14:20:50+10:00"},"yearLevel": {"id": 6,"name": "Year 6"}}`
`{"assessmentId": 256,"title": "English 3/4 [Final]","assessmentType": "dueWork","folder": [{id: 80}],"weighted": false,"workType": {"id": 1,"name": "Formative Assessment"},"dueDate": {"from": "2017-10-12T14:20:50+10:00","to": "2019-10-12T14:20:50+10:00"},"yearLevel": {"id": 6,"name": "Year 6"}}`
schema:
type: object
properties:
Expand All @@ -52,29 +52,38 @@ parameters:
example: dueWork
folder:
oneOf:
- type: array
description: Array for folders to filter assessments on.
items:
type: object
- type: array
description: |
Select either one of the following fields to filter on:
An array of objects, each of which specifies either an "id" or a "code".
items:
oneOf:
- type: object
properties:
id:
description: ID of the folder containing the assessment.
type: integer
example: 80
required:
- id
- type: object
properties:
code:
description: Code of the folder containing the assessment.
type: string
example: 9ENGA
required:
- code
- type: object
deprecated: true
description: |
(Deprecated)
properties:
id:
type: integer
description: ID of the folder containing the assessment.
example: 80
code:
type: string
description: Code of the folder containing the assessment.
example: 9ENGA
- type: object
description: |
Select a folder ID to filter on:
properties:
id:
type: integer
description: ID of the folder containing the assessment.
example: 80
required:
- id
subjectCode:
type: array
items:
Expand Down