MauroDataMapper / mdm-ui

Web front-end for the Mauro Data Mapper
Apache License 2.0
7 stars 5 forks source link

Terminology and Code Set search covers full catalogue #600

Open pjmonks opened 2 years ago

pjmonks commented 2 years ago

Description

As noted in #571, the Mauro backend does not seem to provide a dedicated endpoint to search terminologies or code sets. Something can be submitted but it is not restricted by the root terminology/codeset, instead it searches the entire catalogue.

Steps to reproduce

Send a request to either POST /api/terminologies/{id}/search or POST /api/codeSets/{id}/search with a search payload that seems relevant to those models e.g. search term could be for a term label.

A 200 response if returned, but the search results relate to anything in the catalogue, such as Data Models, Data Types etc, which are not in the same domain.

Expected behavior

Terminology and Code Set search should be restricted to only searching and returning Terms.

aaronforshaw commented 2 years ago

Commit https://github.com/MauroDataMapper/mdm-ui/commit/38993273408333cb267f52d9134ca68e8bcc34c9 fixed the search service for terminologies to use the endpoint POST /api/terminologies/{id}/terms/search

pjmonks commented 2 years ago

Discussing with @aaronforshaw , he believes that this issue is now resolved for Terminologies thanks to PR #622 . What remains is to decide if searching Code Sets are a requirement, which may then require a new endpoint and other small UI changes.