Problem/Motivation
The https://schema.org/identifier property supports key/value pairs for identifiers. In Drupal, identifiers should be dedicated string field with size and pattern limitations.
Proposed resolution
Provide a Schema.org Blueprint Identifier module (schemadotorg_identifier.module) that manages the creation of identifiers as Schema.org types are created.
Notes
- Identifier must be a simple field that allows for queries, apis, views, and tokens
- Identifiers should be grouped together.
- Identifier label via Schema.org need to support any format.
- Identifier still must have a machine/api name.
- Identifier sub-properties (flightNumber, globalLocationNumber, gtin, etc…) should be grouped.
- Identifier field names should be prefixed with 'schema_identifier_*'
- JSON:API should just use the machine name.
- Default identifier should be npi and employee_id
field_prefix: schema_identifier_
field_definitions:
employee_id:
name: Employee ID
label: Employee ID
description: The organization's employee ID.
required: true
max_length: 10
npi:
name: NPI
label: National Provider Identifier (NPI)
description: A unique identification number for covered health care providers.
required: true
max_length: 10
schema_types:
MedicalBusiness:
- npi
MedicalOrganization:
- npi
Person:
- npi
- employee_id
Remaining tasks
Create moduleCreate settingsCreate fieldCreate field groupCreate schemadotorg_identifier/README.mdUpdate doc/MODULES.mdUpdate JSON-LDUpdate JSON:API- Write tests
User interface changes
Identifier support.
API changes
Identifier is no longer automatically added JSON-LD without the schemadotorg_identifier.module.
Data model changes
N/A
Issue fork schemadotorg-3356895
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #2
jrockowitz commentedComment #3
jrockowitz commentedComment #4
jrockowitz commentedComment #5
jrockowitz commentedComment #6
jrockowitz commentedComment #7
jrockowitz commentedComment #9
jrockowitz commentedComment #11
jrockowitz commented