Content HUB UI: Use real search API

Description

Acceptance Criteria

Use the real search API.

API doc:

  • string text (Fuzzy text search)

  • string[] languages

  • string[] levels

  • string[] disciplines

  • string[] licenses (not needed for v1)

  • string[] license_versions (not needed for v1)

  • string[] content_types

  • string[] keywords

  • boolean reviewed (means 0 or 1)

  • boolean can_be_modified (license)

  • boolean allows_commercial_use (license)

  • string sort_by (created_at,updated_at,popularity(default))

  • string sort_type (asc,desc(default))

  • integer size (number of records, between:1,50, default:6)

  • integer from (elasticsearch offset for records, any number, used for pagination)

Using multiple facets will result in increased filter (AND)
e.g. /v1/contents?languages[]=nb&can_be_modified=1 will only show norwegian content where the license allows modification.Using multiple values of the same facet will result in (OR)
e.g. /v1/contents?disciplines[]=engineering&disciplines[]=architecture will show both engineering and architecture results

Acceptance Criteria

None

Assignee

Pål Jørgensen

Reporter

Pål Jørgensen

Funding

None

Code reviewer

None

Released

None

Time tracking

8h

Priority

Medium
Configure