From 04e43bd0ebb6a71d061edc51f58db19d55b05cb0 Mon Sep 17 00:00:00 2001 From: Osma Suominen Date: Tue, 20 Oct 2020 09:56:53 +0300 Subject: [PATCH] Show short name of vocabulary for property values from another vocab --- model/ConceptPropertyValue.php | 2 +- tests/ConceptPropertyValueTest.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/model/ConceptPropertyValue.php b/model/ConceptPropertyValue.php index a952c77a6..5f330162e 100644 --- a/model/ConceptPropertyValue.php +++ b/model/ConceptPropertyValue.php @@ -115,7 +115,7 @@ public function getVocab() public function getVocabName() { - return $this->vocab->getTitle(); + return $this->vocab->getShortName(); } public function addSubMember($member, $lang = '') diff --git a/tests/ConceptPropertyValueTest.php b/tests/ConceptPropertyValueTest.php index f2bf58b28..cf0eccb61 100644 --- a/tests/ConceptPropertyValueTest.php +++ b/tests/ConceptPropertyValueTest.php @@ -94,7 +94,7 @@ public function testGetVocab() { public function testGetVocabName() { $props = $this->concept->getProperties(); $propvals = $props['skos:narrower']->getValues(); - $this->assertEquals('Test ontology', $propvals['Crucian carp http://www.skosmos.skos/test/ta121']->getVocabName()); + $this->assertEquals('Test short', $propvals['Crucian carp http://www.skosmos.skos/test/ta121']->getVocabName()); } /**