Open etj opened 2 months ago
@etj we already mapped these roles via template tag. Do you think that kind of fix/change would resolve this issue? Then we would be happy to provide an upstream PR.
@etj if you intend to support this more natively, we also can think of adding code
to Role
like:
class Role:
def __init__(self, label, code, is_required, is_multivalue, is_toggled_in_metadata_editor):
self.label = label
self.code = code
self.is_required = is_required
self.is_multivalue = is_multivalue
self.is_toggled_in_metadata_editor = is_toggled_in_metadata_editor
def __repr__(self):
return self.label
Codelist values for
gmd:CI_RoleCode
should beauthor
custodian
distributor
originator
owner
pointOfContact
principalInvestigator
processor
publisher
resourceProvider
sponsor
user
In GeoNode they are defined as
https://github.com/GeoNode/geonode/blob/ec24c991c50fc9c0078d3994d35f133608376fbd/geonode/people/__init__.py#L33-L46
where the label is also set as
codeListValue
:https://github.com/GeoNode/geonode/blob/ec24c991c50fc9c0078d3994d35f133608376fbd/geonode/catalogue/templates/catalogue/full_metadata.xml#L78-L80
This values are still not inserted into the xml metadata because of https://github.com/GeoNode/geonode/issues/12533