noi-techpark / it.bz.opendatahub.databrowser

Explore and navigate through Open Data you need to build your next service.
https://databrowser.opendatahub.com
GNU Affero General Public License v3.0
9 stars 7 forks source link

As a databrowser user i want to hide certain properties depending on what type the record is #549

Closed RudiThoeni closed 1 month ago

RudiThoeni commented 8 months ago

Hi @gappc

I have a concrete Usecase where I want to save very "specific" properties into a generic Endpoint like ODHActivityPois. For this reason i added into the ODHActivityPoi Dataschema a dynamic field to store this information. It is possible to save different schemas into this dynamic field...

At example now we have to save the Echarging Properties for Each echargingstation. Therefore i created a Databrowser Section. (https://github.com/noi-techpark/it.bz.opendatahub.databrowser/pull/548) This section shows up on every ODHActivityPoi Edit, so the question is, how much effort would it be to extend the Databrowser to add a condition into the DetailView/EditView for certain sections.

What i mean is to add on the odhActivityPoi.sharedView

    locationCategory(),
    gpsDataCategory(),
    echargingdataCategory(),

something like this

    locationCategory(),
    gpsDataCategory(),
    %A condition that this section shows only up when the Tags contains a category "echarging"% echargingdataCategory(),

What would be a simple, easy and reusable solution for this? thx and cheers Rudi

RudiThoeni commented 8 months ago

Another option could be to create a specific Configuration for Echargingstation, and if the prefiltered dataset with Echargingstations is opened this configuration is used instead of the generic odhActivityPoi Configuration.... Maybe the MetaData Api could be extended to have an optional information which configuration should be used?

What do you think about this

pkritzinger commented 7 months ago

https://5.databrowser.gappc.net/dataset/edit/tourism/v1/ODHActivityPoi/echarging_it*220*ebz000043#additional-properties

-There should be the possibility to choose which Additional Property can be added (restricted to only one Additionalproperty, in future could be we need to add more than one). The List of Additional Properties to add is simply configured in the databrowser (maybe future extension could be to retrieve it from an api, but for the moment let's do it hardcoded) -Then we need also the functionality to remove an Additionalproperty. This removal will delete the content of the Additioalproperty (simply remove it from the Dictionary). This means we have to ask for confirmation.

@gappc @RudiThoeni did I get you correctly that the usecase is as follows: user wants to add/ remove another category (e.g. as in the provided link Echarging data). After adding the category (s)he can select from a list of categories to add one of them. Thanks for letting me know.

pkritzinger commented 6 months ago

@RudiThoeni @gappc just wanted to shortly ask if you could provide feedback on this? thanks in advance.

RudiThoeni commented 6 months ago

@pkritzinger we continued the discussion into this PR https://github.com/noi-techpark/it.bz.opendatahub.databrowser/pull/555

sseppi commented 6 months ago

As agreed in during the sprint meeting, the preferred solution is the following:

https://5.databrowser.gappc.net/dataset/edit/tourism/v1/ODHActivityPoi/echarging_it*220*ebz000043#additional-properties

During the development we have to consider the following notes:

sseppi commented 1 month ago

@RudiThoeni This issue is solved with the implementation of the Additional Properties. right?

RudiThoeni commented 1 month ago

yes we can close it