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

Editor / List formats as protocols. #5465

Merged
merged 4 commits into from
Apr 13, 2021

Conversation

fxprunayre
Copy link
Member

@fxprunayre fxprunayre commented Mar 2, 2021

Adding distribution formats

User populates distribution format eg. ESRI Shapefile and Mapinfo MIF/MID

image

Add online resources related to one of the distribution format

Then when adding an online source (using the associated resources panel), the list of protocols shows:

  • ISO 19139
    • First the list of formats defined in distribution. The value is "WWW:DOWNLOAD:ESRI Shapefile"
    • then the list of protocols defined in the schema configuration

image

  • ISO 19115-3 (which provides a menu to add new online resource)
    • Access the resource section, contains first as many items as formats declared in distribution section
    • KML protocol choices are removed as they have to be declared as a format to be added as online resource.

image

Record download access

Record view render format as a badge when defined

image

Fixes

  • When editing existing online source, don't loose protocol value.

Work done in the context of https://geocat.ch

@fxprunayre fxprunayre added this to the 4.0.4 milestone Mar 2, 2021
@pvgenuchten
Copy link

Yes, i like the idea!

To make available the currently inserted formats as potential protocols to the resource panel

@fxprunayre
Copy link
Member Author

As discussed on other channel, it could make sense that the protocol value is a IANA type if it exists but that would mean to use those values to populate the distribution formats.

@fxprunayre fxprunayre marked this pull request as ready for review April 8, 2021 15:36
@fxprunayre fxprunayre force-pushed the 404-formats-as-protocols branch from fc144f3 to 7127bd7 Compare April 13, 2021 04:50
fxprunayre added a commit to fxprunayre/geocat that referenced this pull request Apr 13, 2021
Copy link
Member

@josegar74 josegar74 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've tested and the combobox sometimes display the sections Distribution formats and General protocols and others no, with the same metadata.

  1. Edit a metadata with distribution formats and add a new online resource -> OK

  2. Edit the online resource --> NO OK (XML and Shapefile are distribution formats), no sections displayed anymore.

online-resources-1

  1. After that adding a new online resources, the protocols list has no sections displayed anymore.

Copy link
Member

@josegar74 josegar74 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested, working fine

@josegar74 josegar74 merged commit 30876ec into geonetwork:4.0.x Apr 13, 2021
cmangeat pushed a commit to geoadmin/geocat that referenced this pull request Apr 23, 2021
fxprunayre added a commit that referenced this pull request May 4, 2021
fxprunayre added a commit to fxprunayre/geocat that referenced this pull request May 4, 2021
fxprunayre added a commit that referenced this pull request May 7, 2021
* Editor / List format as protocol in helper list

Complementary work to #5465

* Editor / List format as protocol in helper list / Disable header rows.
cmangeat pushed a commit to geoadmin/geocat that referenced this pull request May 11, 2021
@fgravin
Copy link
Member

fgravin commented Sep 27, 2021

Work done in the context of https://geocat.ch

Do you have a good example url please ?
I found https://www.geocat.ch/geonetwork/srv/eng/catalog.search#/metadata/f33baf45-a2e9-1e94-2976-67a6f75b53de but i can't figure out how the binding between the resource and the format is done.

BTW, how the gmd:function is used in GN ? I didn't know we were using it ! Looks like it brings additional info.

Thanks

@josegar74
Copy link
Member

Do you have a good example url please ? I found https://www.geocat.ch/geonetwork/srv/eng/catalog.search#/metadata/f33baf45-a2e9-1e94-2976-67a6f75b53de but i can't figure out how the binding between the resource and the format is done.

Checking this code: https://github.com/geonetwork/core-geonetwork/pull/5465/files#diff-f4fda52b9bf213a1ef716f64579b912e3fc0603dd42339a416ab35fcb4f23474R49-R55, it is extracting the formats available in the distribution section to display them as additional protocols in the online resources dialog.

BTW, how the gmd:function is used in GN ? I didn't know we were using it ! Looks like it brings additional info.

I'm not sure if used in GN for any feature, but if not required in your metadata schema, it can be removed from the online resources dialog, removing this section:

"function": {
"isMultilingual": false,
"tooltip": "gmd:function"
},

@fgravin
Copy link
Member

fgravin commented Sep 28, 2021

Checking this code: https://github.com/geonetwork/core-geonetwork/pull/5465/files#diff-f4fda52b9bf213a1ef716f64579b912e3fc0603dd42339a416ab35fcb4f23474R49-R55, it is extracting the formats available in the distribution section to display them as additional protocols in the online resources dialog.

Thanks @josegar74, I understood this but my question was more about the metadata view, how a resource is identified to be a geojson download and have the correct icon.

image

I don't understand how resources are paired to formats in the metadataview.
Is it by the protocol, for instance i see somtimes WWW:DOWNLOAD-APP or WWW:DOWNLOAD: SHAPEFILES but not always...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants