Problem/Motivation

I work at a university and we need to use the 'CollegeOrUniversity' Schema.org Metatag. However, the current 'schema_organization' tag does not include a 'parentOrganization' property, which is required for the 'CollegeOrUniversity' schema type.

Proposed resolution

Add a 'parentOrganization' property to 'schema_organization'
This is our desired output for our specific use case of Schema Organizations:

<script type="application/ld+json">
{
	"@context": "https://schema.org/",
	"@type": "CollegeOrUniversity",
	"name": "University of Arizona {{Department/College}}",
	"url": "{{Department/College url}}",
	"description": "{{Description of department/college}}",
	"logo": "{{Department/College logo}}",
	"image": "{{Image to represent department/college}}",
	"sameAs": "{{comma separated social media URLs}}",
	"address": {
		"@type": "PostalAddress",
		"streetAddress": "{{Street Address}}",
		"addressLocality": "{{City}}",
		"addressRegion": "{{2 letter state abbreviation}}",
		"postalCode": "{{5 digits}}",
		"addressCountry": "{{Country abbreviation}}"
	},
	"telephone": "{{+1-555-555-5555}}",
	"email": "{{Department/College email address}}",
	"parentOrganization": {
		"@type": "EducationalOrganization",
		"name": "University of Arizona",
		"url": "https://www.arizona.edu/",
		"address": {
			"@type": "PostalAddress",
			"streetAddress": "1401 E University Blvd",
			"addressLocality": "Tucson",
			"addressRegion": "AZ",
			"postalCode": "85721",
			"addressCountry": "US"
		}
	}
}
</script>
Command icon 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

mrbeiley created an issue. See original summary.

mrbeiley’s picture

Issue summary: View changes
trackleft2’s picture

Title: Adding a CollegeOrUniversity module » Adding a CollegeOrUniversity tag
Issue tags: -custom module

trackleft2 changed the visibility of the branch 3477869-adding-a-collegeoruniversity-tag to hidden.

joegraduate made their first commit to this issue’s fork.

joegraduate’s picture

Version: 3.0.3 » 3.0.x-dev
Status: Active » Needs work
Issue tags: +Needs issue summary update

MR looks promising. This needs an issue summary update that reflects the suggestion/decision to change this to be a proposal for adding the parentOrganization property to schema_organization instead of adding a separate specific tag for CollegeOrUniversity.

mrbeiley’s picture

Issue summary: View changes
joegraduate’s picture

Title: Adding a CollegeOrUniversity tag » Add parentOrganization property/tag to Organization
joegraduate’s picture

Title: Add parentOrganization property/tag to Organization » Add parentOrganization property/tag to schema_organization

joegraduate’s picture

Status: Needs work » Needs review
Issue tags: -Needs issue summary update
trackleft2’s picture

This works for me, I wonder if we need a follow-up issue to add the email field. Otherwise all required fields are accounted for in this MR.

"email": "{{Department/College email address}}",

joegraduate’s picture

Assigned: mrbeiley » Unassigned
Status: Needs review » Reviewed & tested by the community
mrbeiley’s picture

StatusFileSize
new4.56 KB

Create a static file for adding the Schema Metatag module into composer.json.

mrbeiley’s picture

Status: Reviewed & tested by the community » Needs review
mrbeiley’s picture

StatusFileSize
new4.56 KB

Create a static .diff file for adding the Schema Metatag module into composer.json.

trackleft2’s picture

Status: Needs review » Reviewed & tested by the community
damienmckenna’s picture

This looks great, thank you.

We'll add it to the 3.1.0 release, where the new features will go.

anybody made their first commit to this issue’s fork.

anybody’s picture

Version: 3.0.x-dev » 3.1.x-dev
anybody’s picture

Status: Reviewed & tested by the community » Fixed

Now that this issue is closed, review the contribution record.

As a contributor, attribute any organization that helped you, or if you volunteered your own time.

Maintainers, credit people who helped resolve this issue.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.