Closed t83714 closed 1 year ago
closed via PR: https://github.com/magda-io/magda-ckan-connector/pull/13
Tested with config like:
connector-wa:
config:
id: wa
name: Western Australia Government
sourceUrl: https://catalogue.data.wa.gov.au/
pageSize: 25
customJsFilterCode: |
if(type === "Dataset") {
return jsonData["access_level"]=="open" ? true : false;
} else {
return true;
}
Filter data via custom fields
Some data portal might create their own customised field through CKAN customisation.
e.g. this dataset https://catalogue.data.wa.gov.au/api/3/action/package_show?id=mining-tenements-dmirs-003 contains a custom field
access_level
, which we might need to filter data by.This ticket is about creating a new feature to filter datasets harvested by custom fields.
Possible solution:
Update
We adopted solution option 1: https://github.com/magda-io/magda/issues/3100