From bd73077050a77a35860cd6239ed6c5aa5bebb117 Mon Sep 17 00:00:00 2001
From: Gregor Gawol <gawol@ub.uni-leipzig.de>
Date: Fri, 25 Oct 2019 09:58:31 +0200
Subject: [PATCH] refs #16205 * refactored record-icon.phtml * added additional
 values to display certain icon

---
 .../DefaultRecord/record-icon-class.phtml     |  1 +
 .../DefaultRecord/record-icon.phtml           | 22 +++++++------------
 2 files changed, 9 insertions(+), 14 deletions(-)

diff --git a/themes/fid_adlr/templates/RecordDriver/DefaultRecord/record-icon-class.phtml b/themes/fid_adlr/templates/RecordDriver/DefaultRecord/record-icon-class.phtml
index cc015699802..2abdf79c988 100644
--- a/themes/fid_adlr/templates/RecordDriver/DefaultRecord/record-icon-class.phtml
+++ b/themes/fid_adlr/templates/RecordDriver/DefaultRecord/record-icon-class.phtml
@@ -46,6 +46,7 @@ switch ($normalizedValue) {
     echo 'iconcategory-thesis-offline';
     break;
   case 'thesisonline':
+  case 'thesisonlinefree':
     echo 'iconcategory-thesis-online';
     break;
   case 'visualmedialocal':
diff --git a/themes/fid_adlr/templates/RecordDriver/DefaultRecord/record-icon.phtml b/themes/fid_adlr/templates/RecordDriver/DefaultRecord/record-icon.phtml
index 6e4adfcea44..f8f35ca79cd 100644
--- a/themes/fid_adlr/templates/RecordDriver/DefaultRecord/record-icon.phtml
+++ b/themes/fid_adlr/templates/RecordDriver/DefaultRecord/record-icon.phtml
@@ -1,19 +1,13 @@
 <!-- fid_adlr: recordDriver - DefaultRecord - record-icon -->
 <?php
-if ($this->driver->getRecordType() == "marcfincpda") {
-  $iconClass = $this->record($this->driver)->getRecordIconClass("marcfincpda");
-} elseif ($this->driver->getRecordType() == "lido") {
-  $iconClass = $this->record($this->driver)->getRecordIconClass("object");
-} else {
-  /* finc: solr field facet_avail instead of access_facet (field deprecated) #15375 - GG */
-  $format = $this->driver->getFormats();
-  $format = count($format) > 1 ? $format[0] : $format;
-  $format = is_array($format) ? $format : [$format];
-  $facetAvail = $this->driver->getFacetAvail();
-  $iconValue = array_merge($format, $facetAvail);
-  $iconValue = implode('', $iconValue);
-  $iconClass = $this->record($this->driver)->getRecordIconClass($iconValue);
-}
+/* finc: solr field facet_avail instead of access_facet (field deprecated) #15375 - GG */
+$format = $this->driver->getFormats();
+$format = count($format) > 1 ? $format[0] : $format;
+$format = is_array($format) ? $format : [$format];
+$facetAvail = $this->driver->getFacetAvail();
+$iconValue = array_merge($format, $facetAvail);
+$iconValue = implode('', $iconValue);
+$iconClass = $this->record($this->driver)->getRecordIconClass($iconValue);
 ?>
 <span class="access-icon hidden-print">
   <i class="iconcategory <?=$iconClass?>"></i>
-- 
GitLab