-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
[3.3.x][Fixes #8689] Extend the ResourceBase metadata model with an opaque JSONField #8727
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…paque JSONField
…on base resource
mattiagiupponi
changed the title
WIP - [Fixes #8689] Extend the ResourceBase metadata model with an opaque JSONField
[Fixes #8689] Extend the ResourceBase metadata model with an opaque JSONField
Feb 1, 2022
mattiagiupponi
changed the title
[Fixes #8689] Extend the ResourceBase metadata model with an opaque JSONField
WIP - [Fixes #8689] Extend the ResourceBase metadata model with an opaque JSONField
Feb 2, 2022
mattiagiupponi
changed the title
WIP - [Fixes #8689] Extend the ResourceBase metadata model with an opaque JSONField
[Fixes #8689] Extend the ResourceBase metadata model with an opaque JSONField
Feb 2, 2022
@afabiani the PR for adding the needed validation schema for the client geoapp is available here: GeoNode/geonode-mapstore-client#783 |
12 tasks
afabiani
changed the title
[Fixes #8689] Extend the ResourceBase metadata model with an opaque JSONField
[3.3.x][Fixes #8689] Extend the ResourceBase metadata model with an opaque JSONField
Feb 3, 2022
afabiani
approved these changes
Feb 3, 2022
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@mattiagiupponi let's port this one to master
too
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
refers to #8689
ExtraMetadata
, this model will contain the information about the extra metadata that the resource can have-- Api V2 search into metadata fields:
http://localhost:8000/api/v2/resources?filter{metadata.metadata.icontains}=%22category%22:%20%22bar%22
-- Api V1 search into metadata fields:
http://localhost:8000/api/base/?limit=5&offset=0&metadata__category=object
NOTE: in the API v2, the
icontains
is required sinceDynamicRest
is not able to parseJSON
fields likeDjango ORM
. A pull request was raised in 2020 but is unmerged since the library is not so maintainedGeoApps
,Maps
andDocument
views fixed. In case of errors, the metadata wizard was raising only a "Unknown error", now the correct error is raised to the userGET/Update/delete/add
metadata to the resourcesettings.py
now contains the default structure available for the metadata. This structure is validated and each resource can have its own metadata structurevalidate_extra_metadata
ensure that the structure passed from form/API is the same as the one defined in thesettings.py
file. Is used in bothAPI
andForm
Checklist
For all pull requests:
The following are required only for core and extension modules (they are welcomed, but not required, for contrib modules):
Submitting the PR does not require you to check all items, but by the time it gets merged, they should be either satisfied or inapplicable.