Warning: This page has not been updated in over over a year and may be outdated or deprecated.
indexing:hierarchies_and_collections
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionNext revisionBoth sides next revision | ||
hierarchies_and_collections [2012/11/15 20:02] – demiankatz | indexing:hierarchies_and_collections [2023/03/22 17:57] – demiankatz | ||
---|---|---|---|
Line 1: | Line 1: | ||
====== Hierarchies and Collections ====== | ====== Hierarchies and Collections ====== | ||
- | // The features described on this page are available starting with VuFind | + | // The features described on this page are available starting with VuFind® |
===== Hierarchies ===== | ===== Hierarchies ===== | ||
- | Some document collections are structured hierarchically. | + | Some document collections are structured hierarchically. |
==== Solr Setup ==== | ==== Solr Setup ==== | ||
- | To display hierarchies, | + | To display hierarchies, |
- | * **hierarchytype** - The type of hierarchy being used (this triggers loading of a hierarchy driver; it is usually easiest to leave it blank, causing | + | * **hierarchytype** - The type of hierarchy being used (this triggers loading of a hierarchy driver; it is usually easiest to leave it blank, causing |
+ | * **hierarchy_browse** - Optional, see [[#Setting Up Browsing]] below. | ||
* **hierarchy_top_id** - The Solr ID of the record representing the top of the hierarchy containing the current record. | * **hierarchy_top_id** - The Solr ID of the record representing the top of the hierarchy containing the current record. | ||
* This may be multi-valued if a record belongs to multiple collections. | * This may be multi-valued if a record belongs to multiple collections. | ||
Line 25: | Line 26: | ||
* **is_hierarchy_id** - If the current record represents a node within a hierarchy, this field should contain the same value as the regular id field. | * **is_hierarchy_id** - If the current record represents a node within a hierarchy, this field should contain the same value as the regular id field. | ||
* **is_hierarchy_title** - If the current record represents a node within a hierarchy, this field should contain the same value as the regular title field. | * **is_hierarchy_title** - If the current record represents a node within a hierarchy, this field should contain the same value as the regular title field. | ||
+ | * **title_in_hierarchy** - Optional, introduced in VuFind® 2.3. If a record needs to have a different display title in different collection contexts, this field should contain a number of titles equal to the number of parent collections and in the same order as the hierarchy_parent_id field. | ||
- | ==== VuFind | + | ==== VuFind® |
- | Once the Solr index is populated appropriately, | + | Once the Solr index is populated appropriately, |
- | * In [[config.ini]], | + | * In [[configuration: |
- | * In your hierarchy driver configuration file (usually HierarchyDefault.ini in the same directory as [[config.ini]]), | + | * In your hierarchy driver configuration file (usually HierarchyDefault.ini in the same directory as [[configuration: |
* If you are using Solr to construct tree data, you may also want to set up util/ | * If you are using Solr to construct tree data, you may also want to set up util/ | ||
- | * You can optionally enable or disable searching within trees (a search causes items within the tree to highlight if they match the query); this is on by default and can be controlled within the [Hierarchy] section of [[config.ini]]. | + | * You can optionally enable or disable searching within trees (a search causes items within the tree to highlight if they match the query); this is on by default and can be controlled within the [Hierarchy] section of [[configuration: |
+ | |||
+ | ===== Simple Links Between Containers and Child Records ===== | ||
+ | |||
+ | Beginning with version 2.4 it is also possible to use the hierarchy support for simple links between containers and their contents. This is typically useful when the full hierarchy support would be overkill. Here it is assumed that the hierarchy is shallow and there are only containers and their child records (e.g. journal and articles). In practice the simple link support does two things: | ||
+ | |||
+ | - Replaces the linking from a child record to container by title with linking by record ID. | ||
+ | - Displays the number of child records in the container record page with a link to find them all. | ||
+ | |||
+ | Simple links require only a subset of hierarchy fields: | ||
+ | |||
+ | - The container record must have is_hierarchy_id | ||
+ | - The child records must have hierarchy_parent_id | ||
+ | - Additionally, | ||
+ | - Child records may also have container_reference which is displayed after the link and may include e.g. issue and page number. | ||
+ | |||
+ | If the prerequisites above are fulfilled, the simple links can be enabled by setting simpleContainerLinks to true in [Hierarchy] section of [[configuration: | ||
===== Collections ===== | ===== Collections ===== | ||
- | // Coming soon. // | + | Once you have hierarchies set up, you have the option of enabling VuFind®' |
+ | |||
+ | VuFind®' | ||
+ | |||
+ | ==== Configuration ==== | ||
+ | |||
+ | === Enabling Collection View === | ||
+ | |||
+ | To enable collections, | ||
+ | |||
+ | === Customizing Collection View === | ||
+ | |||
+ | The collection view is actually a hybrid between a record view and a search results screen. | ||
+ | |||
+ | Additional collection-related options can be found in the [Collections] section of [[configuration: | ||
+ | |||
+ | === Identifying Collections === | ||
+ | |||
+ | Further configuration options can be found in your hierarchy driver configuration file (usually HierarchyDefault.ini in the same folder as [[configuration: | ||
+ | |||
+ | * Top - Only records at the top of a hierarchy tree are treated as collections. | ||
+ | * All - Any record marked as a node within the hierarchy (i.e. with is_hierarchy_id set in the Solr index) will be treated as a collection. | ||
+ | * None - This disables collections for all records using this hierarchy driver. | ||
+ | |||
+ | === Browsing Collections === | ||
+ | |||
+ | In addition to the custom collection view, VuFind® also offers a module for browsing through lists of your collections. | ||
+ | |||
+ | == Setting Up Browsing == | ||
+ | |||
+ | In order to browse collections, | ||
+ | |||
+ | Examples: | ||
+ | |||
+ | // | ||
+ | hierarchy_top_id = 1234 | ||
+ | hierarchy_top_title = My Collection | ||
+ | hierarchy_browse = My Collection{{{_ID_}}}1234 | ||
+ | |||
+ | // | ||
+ | hierarchy_parent_id = 1234 | ||
+ | hierarchy_parent_title = My Collection | ||
+ | hierarchy_browse = My Collection{{{_ID_}}}1234 | ||
+ | |||
+ | |||
+ | == Browse Types == | ||
+ | |||
+ | By default, the collection browse uses Solr faceting to find a list of collections. | ||
---- struct data ---- | ---- struct data ---- | ||
+ | properties.Page Owner : | ||
---- | ---- | ||
indexing/hierarchies_and_collections.txt · Last modified: 2023/11/28 20:13 by demiankatz