Skip to content
Snippets Groups Projects
Commit 3ba3a0e8 authored by Demian Katz's avatar Demian Katz
Browse files

Removed deprecated methods; added note about duplication.

parent c7b5bc63
Branches
Tags
No related merge requests found
......@@ -1404,6 +1404,9 @@ class SolrDefault extends AbstractBase
/**
* Get the value of whether or not this is a collection level record
*
* NOTE: \VuFind\Hierarchy\TreeDataFormatter\AbstractBase::isCollection()
* duplicates some of this logic.
*
* @return bool
*/
public function isCollection()
......@@ -1430,48 +1433,6 @@ class SolrDefault extends AbstractBase
}
}
/**
* Get the positions of this item within parent collections. Returns an array
* of parent ID => sequence number.
*
* @return array
*/
public function getHierarchyPositionsInParents()
{
$retVal = [];
if (isset($this->fields['hierarchy_parent_id'])
&& isset($this->fields['hierarchy_sequence'])
) {
foreach ($this->fields['hierarchy_parent_id'] as $key => $val) {
$retVal[$val] = $this->fields['hierarchy_sequence'][$key];
}
}
return $retVal;
}
/**
* Get the titles of this item within parent collections. Returns an array
* of parent ID => sequence number.
*
* @return Array
*/
public function getTitlesInHierarchy()
{
$retVal = [];
if (isset($this->fields['title_in_hierarchy'])
&& is_array($this->fields['title_in_hierarchy'])
) {
$titles = $this->fields['title_in_hierarchy'];
$parentIDs = $this->fields['hierarchy_parent_id'];
if (count($titles) === count($parentIDs)) {
foreach ($parentIDs as $key => $val) {
$retVal[$val] = $titles[$key];
}
}
}
return $retVal;
}
/**
* Get a list of hierarchy trees containing this record.
*
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment