diff --git a/themes/finc/js/lightbox.js b/themes/finc/js/lightbox.js new file mode 100644 index 0000000000000000000000000000000000000000..17e429708bac72f025bb0a06dad804f9dc0f83e9 --- /dev/null +++ b/themes/finc/js/lightbox.js @@ -0,0 +1,439 @@ +/*global recaptchaOnLoad, resetCaptcha, VuFind, TEMPORARY BARF CK*/ +VuFind.register('lightbox', function Lightbox() { + // State + var _originalUrl = false; + var _currentUrl = false; + var _lightboxTitle = false; + var refreshOnClose = false; + var _modalParams = {}; + // Elements + var _modal, _modalBody, _modalTitle, _clickedButton = null; + // Utilities + function _storeClickedStatus() { + _clickedButton = this; + } + function _html(content) { + _modalBody.html(content); + // Set or update title if we have one + if (_lightboxTitle) { + _modalTitle.text(_lightboxTitle); + _lightboxTitle = false; + } + _modal.modal('handleUpdate'); + } + function _emit(msg, _details) { + var details = _details || {}; + var event; + try { + event = new CustomEvent(msg, { + detail: details, + bubbles: true, + cancelable: true + }); + } catch (e) { + // Fallback to document.createEvent() if creating a new CustomEvent fails (e.g. IE 11) + event = document.createEvent('CustomEvent'); + event.initCustomEvent(msg, true, true, details); + } + return document.dispatchEvent(event); + } + + // Public: Present an alert + function showAlert(message, _type) { + var type = _type || 'info'; + _html('<div class="flash-message alert alert-' + type + '">' + message + '</div>' + + '<button class="btn btn-default" data-dismiss="modal">' + VuFind.translate('close') + '</button>'); + _modal.modal('show'); + } + function flashMessage(message, _type) { + var type = _type || 'info'; + _modalBody.find('.flash-message,.fa.fa-spinner').remove(); + _modalBody.find('h2:first-of-type') + .after('<div class="flash-message alert alert-' + type + '">' + message + '</div>'); + } + function close() { + _modal.modal('hide'); + } + + /** + * Update content + * + * Form data options: + * + * data-lightbox-ignore = do not submit this form in lightbox + */ + // function declarations to avoid style warnings about circular references + var _constrainLink; + var _formSubmit; + function render(content) { + if (typeof content !== "string") { + return; + } + // Isolate successes + var htmlDiv = $('<div/>').html(content); + var alerts = htmlDiv.find('.flash-message.alert-success:not([data-lightbox-ignore])'); + if (alerts.length > 0) { + var msgs = alerts.toArray().map(function getSuccessHtml(el) { + return el.innerHTML; + }).join('<br/>'); + var href = alerts.find('.download').attr('href'); + if (typeof href !== 'undefined') { + location.href = href; + close(); + } else { + showAlert(msgs, 'success'); + } + return; + } + // Deframe HTML + var finalHTML = content; + if (content.match('<!DOCTYPE html>')) { + finalHTML = htmlDiv.find('.main > .container').html(); + } + // Fill HTML + _html(finalHTML); + VuFind.modal('show'); + // Attach capturing events + _modalBody.find('a').click(_constrainLink); + // Handle submit buttons attached to a form as well as those in a form. Store + // information about which button was clicked here as checking focused button + // doesn't work on all browsers and platforms. + _modalBody.find('[type=submit]').click(_storeClickedStatus); + + var forms = _modalBody.find('form:not([data-lightbox-ignore])'); + for (var i = 0; i < forms.length; i++) { + $(forms[i]).on('submit', _formSubmit); + } + // Select all checkboxes + $('#modal').find('.checkbox-select-all').change(function lbSelectAllCheckboxes() { + $(this).closest('.modal-body').find('.checkbox-select-item').prop('checked', this.checked); + }); + $('#modal').find('.checkbox-select-item').change(function lbSelectAllDisable() { + $(this).closest('.modal-body').find('.checkbox-select-all').prop('checked', false); + }); + // Recaptcha + recaptchaOnLoad(); + } + + var _xhr = false; + // Public: Handle AJAX in the Lightbox + function ajax(obj) { + if (_xhr !== false) { + return; + } + if (_originalUrl === false) { + _originalUrl = obj.url; + } + // Add lightbox GET parameter + if (!obj.url.match(/layout=lightbox/)) { + var parts = obj.url.split('#'); + obj.url = parts[0].indexOf('?') < 0 + ? parts[0] + '?' + : parts[0] + '&'; + obj.url += 'layout=lightbox'; + if (_currentUrl) { + obj.url += '&lbreferer=' + encodeURIComponent(_currentUrl); + } + obj.url += parts.length < 2 ? '' : '#' + parts[1]; + } + _xhr = $.ajax(obj); + _xhr.always(function lbAjaxAlways() { _xhr = false; }) + .done(function lbAjaxDone(content, status, jq_xhr) { + var errorMsgs = []; + var flashMessages = []; + if (jq_xhr.status === 204) { + // No content, close lightbox + close(); + return; + } else if (jq_xhr.status !== 205) { + var testDiv = $('<div/>').html(content); + errorMsgs = testDiv.find('.flash-message.alert-danger:not([data-lightbox-ignore])'); + flashMessages = testDiv.find('.flash-message:not([data-lightbox-ignore])'); + // Place Hold error isolation + if (obj.url.match(/\/Record\/.*(Hold|Request)\?/)) { + if (errorMsgs.length && testDiv.find('.record').length) { + var msgs = errorMsgs.toArray().map(function getAlertHtml(el) { + return el.innerHTML; + }).join('<br/>'); + showAlert(msgs, 'danger'); + return false; + } + } + } + // Close the lightbox after deliberate login provided that: + // - is a form + // - catalog login for holds + // - or that matches login/create account + // - not a failed login + if ( + obj.method && ( + obj.url.match(/catalogLogin/) + || obj.url.match(/MyResearch\/(?!Bulk|Delete|Recover)/) + ) && flashMessages.length === 0 + ) { + + var eventResult = _emit('VuFind.lightbox.login', { + originalUrl: _originalUrl, + formUrl: obj.url + }); + if (_originalUrl.match(/UserLogin/) || obj.url.match(/catalogLogin/)) { + if (eventResult) { + VuFind.refreshPage(); + } + return false; + } else { + VuFind.lightbox.refreshOnClose = true; + } + _currentUrl = _originalUrl; // Now that we're logged in, where were we? + } + if (jq_xhr.status === 205) { + VuFind.refreshPage(); + return; + } + render(content); + }) + .fail(function lbAjaxFail(deferred, errorType, msg) { + showAlert(VuFind.translate('error_occurred') + '<br/>' + msg, 'danger'); + }); + return _xhr; + } + function reload() { + ajax({ url: _currentUrl || _originalUrl }); + } + + /** + * Evaluate a callback + */ + function _evalCallback(callback, event, data) { + if ('function' === typeof window[callback]) { + return window[callback](event, data); + } + var parts = callback.split('.'); + if (typeof window[parts[0]] === 'object') { + var obj = window[parts[0]]; + for (var i = 1; i < parts.length; i++) { + if (typeof obj[parts[i]] === 'undefined') { + obj = false; + break; + } + obj = obj[parts[i]]; + } + if ('function' === typeof obj) { + return obj(event, data); + } + } + console.error('Lightbox callback function not found.'); + return null; + } + + /** + * Modal link data options + * + * data-lightbox-href = go to this url instead + * data-lightbox-ignore = do not open this link in lightbox + * data-lightbox-post = post data + * data-lightbox-title = Lightbox title (overrides any title the page provides) + */ + _constrainLink = function constrainLink(event) { + /** + * Fixme: TEST correct Lightbox behavior as in #13088 - CK + */ + if (typeof $(this).data('lightboxReset') !== 'undefined') { + VuFind.lightbox.reset(); + } + var $link = $(this); + if (typeof $link.data("lightboxIgnore") != "undefined" + || typeof $link.attr("href") === "undefined" + || $link.attr("href").charAt(0) === "#" + || $link.attr("href").match(/^[a-zA-Z]+:[^/]/) // ignore resource identifiers (mailto:, tel:, etc.) + || (typeof $link.attr("target") !== "undefined" + && ( + $link.attr("target").toLowerCase() === "_new" + || $link.attr("target").toLowerCase() === "new" + )) + ) { + return true; + } + if (this.href.length > 1) { + event.preventDefault(); + var obj = {url: $(this).data('lightboxHref') || this.href}; + if ("string" === typeof $(this).data('lightboxPost')) { + obj.type = 'POST'; + obj.data = $(this).data('lightboxPost'); + } + _lightboxTitle = $(this).data('lightbox-title'); + _modalParams = $(this).data(); + VuFind.modal('show'); + ajax(obj); + _currentUrl = this.href; + return false; + } + }; + + /** + * Handle form submission. + * + * Form data options: + * + * data-lightbox-onsubmit = on submit, run named function + * data-lightbox-onclose = on close, run named function + * data-lightbox-title = Lightbox title (overrides any title the page provides) + * + * Submit button data options: + * + * data-lightbox-ignore = do not handle clicking this button in lightbox + */ + _formSubmit = function formSubmit(event) { + // Gather data + var form = event.target; + var data = $(form).serializeArray(); + // Force layout + data.push({ name: 'layout', value: 'lightbox' }); // Return in lightbox, please + // Add submit button information + var submit = $(_clickedButton); + _clickedButton = null; + var buttonData = { name: 'submit', value: 1 }; + if (submit.length > 0) { + if (typeof submit.data('lightbox-close') !== 'undefined') { + close(); + return false; + } + if (typeof submit.data('lightbox-ignore') !== 'undefined') { + return true; + } + buttonData.name = submit.attr('name') || 'submit'; + buttonData.value = submit.attr('value') || 1; + } + data.push(buttonData); + // Special handlers + // On submit behavior + if ('string' === typeof $(form).data('lightboxOnsubmit')) { + var ret = _evalCallback($(form).data('lightboxOnsubmit'), event, data); + // return true or false to send that to the form + // return null or anything else to continue to the ajax + if (ret === false || ret === true) { + return ret; + } + } + // onclose behavior + if ('string' === typeof $(form).data('lightboxOnclose')) { + document.addEventListener('VuFind.lightbox.closed', function lightboxClosed(e) { + this.removeEventListener('VuFind.lightbox.closed', arguments.callee); + _evalCallback($(form).data('lightboxOnclose'), e, form); + }, false); + } + // Loading + _modalBody.prepend('<i class="modal-loading fa fa-spinner fa-spin" title="' + VuFind.translate('loading') + '"></i>'); + // Prevent multiple submission of submit button in lightbox + if (submit.closest(_modal).length > 0) { + submit.attr('disabled', 'disabled'); + } + // Store custom title + _lightboxTitle = submit.data('lightboxTitle') || $(form).data('lightboxTitle') || ''; + // Get Lightbox content + ajax({ + url: $(form).attr('action') || _currentUrl, + method: $(form).attr('method') || 'GET', + data: data + }).done(function recaptchaReset() { + resetCaptcha($(form)); + }); + + VuFind.modal('show'); + return false; + }; + + // Public: Attach listeners to the page + function bind(el) { + var target = el || document; + $(target).find('a[data-lightbox]') + .unbind('click', _constrainLink) + .on('click', _constrainLink); + $(target).find('form[data-lightbox]') + .unbind('submit', _formSubmit) + .on('submit', _formSubmit); + + // Handle submit buttons attached to a form as well as those in a form. Store + // information about which button was clicked here as checking focused button + // doesn't work on all browsers and platforms. + $('form[data-lightbox]').each(function bindFormSubmitsLightbox(i, form) { + $(form).find('[type=submit]').click(_storeClickedStatus); + $('[type="submit"][form="' + form.id + '"]').click(_storeClickedStatus); + }); + + // Display images in the lightbox + $('[data-lightbox-image]', el).each(function lightboxOpenImage(i, link) { + $(link).unbind("click", _constrainLink); + $(link).bind("click", function lightboxImageRender(event) { + event.preventDefault(); + var url = link.dataset.lightboxHref || link.href || link.src; + var imageCheck = $.ajax({ + url: url, + method: "HEAD" + }); + imageCheck.done(function lightboxImageCheckDone(content, status, jq_xhr) { + if ( + jq_xhr.status === 200 && + jq_xhr.getResponseHeader("content-type").substr(0, 5) === "image" + ) { + render('<div class="lightbox-image"><img src="' + url + '"/></div>'); + } else { + location.href = url; + } + }); + }); + }); + } + + function reset() { + _html(VuFind.translate('loading') + '...'); + _originalUrl = false; + _currentUrl = false; + _lightboxTitle = ''; + _modalParams = {}; + } + function init() { + _modal = $('#modal'); + _modalBody = _modal.find('.modal-body'); + _modalTitle = _modal.find("#modal-title"); + _modal.on('hide.bs.modal', function lightboxHide() { + if (VuFind.lightbox.refreshOnClose) { + VuFind.refreshPage(); + } + this.setAttribute('aria-hidden', true); + _emit('VuFind.lightbox.closing'); + }); + _modal.on('hidden.bs.modal', function lightboxHidden() { + VuFind.lightbox.reset(); + _emit('VuFind.lightbox.closed'); + }); + + VuFind.modal = function modalShortcut(cmd) { + if (cmd === 'show') { + _modal.modal($.extend({ show: true }, _modalParams)).attr('aria-hidden', false); + } else { + _modal.modal(cmd); + } + }; + bind(); + } + + // Reveal + return { + // Properties + refreshOnClose: refreshOnClose, + + // Methods + ajax: ajax, + alert: showAlert, + bind: bind, + close: close, + flashMessage: flashMessage, + reload: reload, + render: render, + // Reset + reset: reset, + // Init + init: init + }; +}); diff --git a/themes/finc/scss/compiled.scss b/themes/finc/scss/compiled.scss index b0146b6727da6286d187bce0409cf6981f142977..e9dd655e78a6f31ce82ed4037acf91337daa2ea5 100644 --- a/themes/finc/scss/compiled.scss +++ b/themes/finc/scss/compiled.scss @@ -691,6 +691,12 @@ table.collapse.in { //// Display styleBasedIcons .record, .result { + // make sure that results items display correctly on XS + .media { + padding-left: 0; + padding-right: 0; + } + .media-left, .media-right { &.record-icon img { @@ -1216,7 +1222,7 @@ header, @media (min-width: $screen-sm-min) { background-color: $navbar-bg-color; position: absolute; - top: $navbar-height-xs * 1.5; + top: calc(#{$navbar-height-xs} * 1.5); // Use this formula to allow for separately calculated $navbar-height in themes } } @@ -1228,6 +1234,10 @@ header, } } +.language.dropdown { + margin-right: 15px; +} + .language .dropdown-menu { background-color: $navbar-bg-color; border: 0; @@ -1237,6 +1247,10 @@ header, background-color: $btn-language-hover-bg; } + .active .btn:hover { + background-color: $btn-language-active-hover-bg; + } + li a { color: $link-color; @@ -1294,7 +1308,7 @@ header, #header-collapse.collapse.in { @media (max-width: $screen-sm-max) { background-color: $header-bg-color; - // margin-top: -$navbar-height-xs - 10px; // pull over searchbox + // margin-top: -($navbar-height-xs) - 10px; // pull over searchbox li > a.btn { text-align: left; @@ -1850,6 +1864,7 @@ footer { } } } + //////// Tab-content active needs to display 'inline-block' top display the border correctly (or content will bleed over) .tab-content > .active { display: inline-block; @@ -2030,7 +2045,7 @@ footer { } } - ////// Swap find and clear buttons for consistency +////// Swap find and clear buttons for consistency .adv-submit { .fnd-btn { float: right; @@ -2639,16 +2654,3 @@ input { color: $btn-transparent-active-color; } } - -// Accessibility -.language .dropdown-menu { - .btn:hover { - background-color: $btn-language-hover-bg; - } - - .active .btn:hover { - background-color: $btn-language-active-hover-bg; - } -} - -// Accessibility - END diff --git a/themes/finc/templates/Email/journalhold-html.phtml b/themes/finc/templates/Email/journalhold-html.phtml index 04bde33c945cf81ca4639135fac4f5c524a04fd0..19012274a63f288282d7e6e65e0ec3ef4d3bc42f 100644 --- a/themes/finc/templates/Email/journalhold-html.phtml +++ b/themes/finc/templates/Email/journalhold-html.phtml @@ -13,7 +13,7 @@ </td> <td width="275"> <strong>Heft / Jahrgang / Band:</strong><br/> - <?=$this->year?> / <?=$this->issue?> / <?=$this->volume?> + <?=$this->issue?> / <?=$this->year?> / <?=$this->volume?> </td> <td width="50"> @@ -21,7 +21,7 @@ <td width="220" rowspan="3" align="center" valign="top"> <strong><?=$this->callnumber?></strong><br/> Jahrgang / Band / Heft:<br/> - <strong><?=$this->year?> / <?=$this->issue?> / <?=$this->volume?></strong><br/> + <strong><?=$this->year?> / <?=$this->volume?> / <?=$this->issue?> </strong><br/> <strong><?=$this->record['title']?></strong><br/><br/> </td> </tr> diff --git a/themes/finc/templates/Helpers/branchinfo.phtml b/themes/finc/templates/Helpers/branchinfo.phtml index 248ce1ff9088e8082342672edf7467d5f5cca618..e3a481f15d01d838e954e73eb045662b2eb246af 100644 --- a/themes/finc/templates/Helpers/branchinfo.phtml +++ b/themes/finc/templates/Helpers/branchinfo.phtml @@ -1,80 +1,85 @@ <!-- helpers - branchinfo.phtml --> -<tr class="holding-info"> - <td colspan="4"> - <?php /* Keep the accordion-toggler! It makes the link appear as an accordion header - CK */ ?> - <a href="#<?=$info['branchno']?>" class="accordion-toggler" data-toggle="collapse" aria-expanded="false"><?=$this->transEsc('Address-Contact-Hours')?></a> - <div id="<?=$info['branchno']?>" class="collapse" aria-expanded="false"> - <div class="branch-address col-xs-12 col-sm-6"> - <strong><?=$info['branch']?></strong><br/> - <?=$info['streetaddress']?><br/> - <?=$info['postalcode']?> <?=$info['city']?> - </div> - <div class="branch-contact col-xs-12 col-sm-6"> - <?php if (isset($info['tel'])): ?> - <?php if (is_array($info['tel'])): ?> - <?php foreach ($info['tel'] as $tel): ?> - <?=$this->transEsc('Tel')?>: <?=$tel?><br/> - <?php endforeach; ?> - <?php else: ?> - <?=$this->transEsc('Tel')?>: <?=$info['tel']?><br/> - <?php endif; ?> - <?php endif; ?> - <?php if (isset($info['fax'])): ?> - <?=$this->transEsc('Fax')?>: <?=$info['fax']?><br/> - <?php endif; ?> - <?php if ( - isset($info['email']) - && is_array($info['email']) - && count($info['email']) > 0 - ): ?> - <?php foreach ($info['email'] as $email): ?> - <?=$this->transEsc('Email')?>: <?=$email?><br/> - <?php endforeach; ?> - <?php else: ?> - <?=$this->transEsc('Email')?>: <?=$info['email']?><br/> - <?php endif; ?> - <?php if (isset($info['url'])): ?> - <a href="<?=$info['url']?>" title="<?=$info['branch']?>"> - <?php if (isset($info['branch'])): ?> - <?=$this->transEsc('Link to')?> +<table> + <caption class="sr-only"> + <?= $this->transEsc('Address-Contact-Hours') ?> + </caption> + <tr class="holding-info"> + <td colspan="4"> + <?php /* Keep the accordion-toggler! It makes the link appear as an accordion header - CK */ ?> + <a href="#<?= $info['branchno'] ?>" class="accordion-toggler" data-toggle="collapse" aria-expanded="false"><?= $this->transEsc('Address-Contact-Hours') ?></a> + <div id="<?= $info['branchno'] ?>" class="collapse" aria-expanded="false"> + <div class="branch-address col-xs-12 col-sm-6"> + <strong><?= $info['branch'] ?></strong><br/> + <?= $info['streetaddress'] ?><br/> + <?= $info['postalcode'] ?> <?= $info['city'] ?> + </div> + <div class="branch-contact col-xs-12 col-sm-6"> + <?php if (isset($info['tel'])): ?> + <?php if (is_array($info['tel'])): ?> + <?php foreach ($info['tel'] as $tel): ?> + <?= $this->transEsc('Tel') ?>: <?= $tel ?><br/> + <?php endforeach; ?> + <?php else: ?> + <?= $this->transEsc('Tel') ?>: <?= $info['tel'] ?><br/> + <?php endif; ?> + <?php endif; ?> + <?php if (isset($info['fax'])): ?> + <?= $this->transEsc('Fax') ?>: <?= $info['fax'] ?><br/> + <?php endif; ?> + <?php if ( + isset($info['email']) + && is_array($info['email']) + && count($info['email']) > 0 + ): ?> + <?php foreach ($info['email'] as $email): ?> + <?= $this->transEsc('Email') ?>: <?= $email ?><br/> + <?php endforeach; ?> <?php else: ?> - <?=$info['url']?> + <?= $this->transEsc('Email') ?>: <?= $info['email'] ?><br/> + <?php endif; ?> + <?php if (isset($info['url'])): ?> + <a href="<?= $info['url'] ?>" title="<?= $info['branch'] ?>"> + <?php if (isset($info['branch'])): ?> + <?= $this->transEsc('Link to') ?> + <?php else: ?> + <?= $info['url'] ?> + <?php endif; ?> + </a> <?php endif; ?> - </a> - <?php endif; ?> + </div> + <div class="branch-hours col-xs-12"> + <?php if ( + isset($info['openinghours']) + && is_array($info['openinghours']) + && count($info['openinghours']) > 0 + ): ?> + <?php if (isset($info['branchpart'])): ?> + <strong><?= $info['branchpart'] ?></strong> + <?php endif; ?> + <?php if ($info['branchno'] != 'zw02'): ?> + <?= $this->transEsc('Opening hours') ?><br/> + <?php endif; ?> + <?php foreach ($info['openinghours'] as $line): ?> + <?= $line['days'] ?>: <?= $line['open'] ?> – <?= $line['close'] ?><br/> + <?php endforeach; ?> + <?php endif; ?> + </div> </div> - <div class="branch-hours col-xs-12"> - <?php if ( - isset($info['openinghours']) - && is_array($info['openinghours']) - && count($info['openinghours']) > 0 - ): ?> - <?php if (isset($info['branchpart'])): ?> - <strong><?=$info['branchpart']?></strong> + <div class="row"> + <?php if (isset($info['note'])): ?> + <div class="branch-note alert alert-info"> + <?php if (is_array($info['note'])): ?> + <?php foreach ($info['note'] as $notes): ?> + <?= $notes ?> + <?php endforeach; ?> + <?php else: ?> + <?= $info['note'] ?> + <?php endif; ?> + </div> <?php endif; ?> - <?php if ($info['branchno'] != 'zw02'): ?> - <?=$this->transEsc('Opening hours')?><br/> - <?php endif; ?> - <?php foreach ($info['openinghours'] as $line): ?> - <?=$line['days']?>: <?=$line['open']?> – <?=$line['close']?><br/> - <?php endforeach; ?> - <?php endif; ?> </div> - </div> - <div class="row"> - <?php if (isset($info['note'])): ?> - <div class="branch-note alert alert-info"> - <?php if (is_array($info['note'])): ?> - <?php foreach ($info['note'] as $notes): ?> - <?=$notes?> - <?php endforeach; ?> - <?php else: ?> - <?=$info['note']?> - <?php endif; ?> - </div> - <?php endif; ?> - </div> - </td> -</tr> -<?=$this->headScript()?> + </td> + </tr> +</table> +<?= $this->headScript() ?> <!-- helpers - branchinfo.phtml - END --> diff --git a/themes/finc/templates/RecordDriver/DefaultRecord/list-entry.phtml b/themes/finc/templates/RecordDriver/DefaultRecord/list-entry.phtml index 0cbc0f4761033282ed3a6d41594aacaef19940fe..c3381f131baaa6724b1c7ca2ea84bad9af34e510 100644 --- a/themes/finc/templates/RecordDriver/DefaultRecord/list-entry.phtml +++ b/themes/finc/templates/RecordDriver/DefaultRecord/list-entry.phtml @@ -54,7 +54,7 @@ if ($cover): <div class="resultItemLine2"> <?php if ($this->driver->isCollection()): ?> - <?=implode('<br>', array_map([$this, 'escapeHtml'], $this->driver->getSummary()));?> + <?=implode('<br>', array_map([$this, 'escapeHtml'], $this->driver->getSummary())); ?> <?php else: ?> <?php $summAuthors = $this->driver->getPrimaryAuthors(); if (!empty($summAuthors)): ?> @@ -69,8 +69,7 @@ if ($cover): $summDate = $this->driver->getPublicationDates(); ?> <?php if (!empty($journalTitle)): ?> <?=!empty($summAuthor) ? '<br/>' : ''?> - <?=/* TODO: handle highlighting more elegantly here */ - $this->transEsc('Published in') . ' <a href="' . $this->record($this->driver)->getLink('journaltitle', str_replace(['{{{{START_HILITE}}}}', '{{{{END_HILITE}}}}'], '', $journalTitle)) . '">' . $this->highlight($journalTitle) . '</a>';?> + <?=/* TODO: handle highlighting more elegantly here */ $this->transEsc('Published in') . ' <a href="' . $this->record($this->driver)->getLink('journaltitle', str_replace(['{{{{START_HILITE}}}}', '{{{{END_HILITE}}}}'], '', $journalTitle)) . '">' . $this->highlight($journalTitle) . '</a>';?> <?=!empty($summDate) ? ' (' . $this->escapeHtml($summDate[0]) . ')' : ''?> <?php elseif (!empty($summDate)): ?> <?=!empty($summAuthor) ? '<br/>' : ''?> @@ -127,7 +126,7 @@ if ($cover): <strong><?=$this->transEsc('Saved in')?>:</strong> <?php $i = 0; foreach ($this->lists as $current): ?> - <a href="<?=$this->url('userList', ['id' => $current->id])?>"><?=$this->escapeHtml($current->title)?></a><?php if ($i++ < count($this->lists) - 1): ?>,<?php endif; ?> + <a href="<?=$this->url('userList', ['id' => $current->id])?>"><?=$this->escapeHtml($current->title)?></a><?php if($i++ < count($this->lists) - 1): ?>,<?php endif; ?> <?php endforeach; ?> <br/> <?php endif; ?> diff --git a/themes/finc/templates/RecordDriver/DefaultRecord/offcanvas-toggler-myresearch.phtml b/themes/finc/templates/RecordDriver/DefaultRecord/offcanvas-toggler-myresearch.phtml index 7baae6a4f2e2399adf117d7e988285877211aed8..3a0f991d8c718e6956ad65a2ad51fe92f3830328 100644 --- a/themes/finc/templates/RecordDriver/DefaultRecord/offcanvas-toggler-myresearch.phtml +++ b/themes/finc/templates/RecordDriver/DefaultRecord/offcanvas-toggler-myresearch.phtml @@ -1,8 +1,8 @@ <!-- finc: RecordDriver - DefaultRecord - offcanvas-toggler-myresearch --> <?php ?> <span class="offcanvas-toggler"> - <button class="search-filter-toggle btn btn-primary visible-xs" href="#search-sidebar" data-toggle="offcanvas" title="<?=$this->transEsc('sidebar_expand')?>"> + <a class="search-filter-toggle btn btn-primary visible-xs" href="#myresearch-sidebar" data-toggle="offcanvas" title="<?=$this->transEsc('sidebar_expand')?>"> <?=$this->transEsc('offcanvas-toggler-myresearch')?> - </button> + </a> </span> <!-- finc: RecordDriver - DefaultRecord - offcanvas-toggler-myresearch - END --> diff --git a/themes/finc/templates/RecordDriver/DefaultRecord/offcanvas-toggler.phtml b/themes/finc/templates/RecordDriver/DefaultRecord/offcanvas-toggler.phtml index a44ef4dfd660838528306c85c3d9ba81ebe41eb6..aa6b8054f3cc968367097f1c570c0f9ef6d3db7b 100644 --- a/themes/finc/templates/RecordDriver/DefaultRecord/offcanvas-toggler.phtml +++ b/themes/finc/templates/RecordDriver/DefaultRecord/offcanvas-toggler.phtml @@ -1,8 +1,8 @@ <!-- finc: RecordDriver - DefaultRecord - offcanvas-toggler --> <?php ?> <span class="offcanvas-toggler"> - <button class="search-filter-toggle btn btn-primary visible-xs" href="#search-sidebar" data-toggle="offcanvas" title="<?=$this->transEsc('sidebar_expand')?>"> + <a class="search-filter-toggle btn btn-primary visible-xs" href="#myresearch-sidebar" data-toggle="offcanvas" title="<?=$this->transEsc('sidebar_expand')?>"> <?=$this->transEsc('offcanvas-toggler-record-view')?> - </button> + </a> </span> <!-- finc: RecordDriver - DefaultRecord - offcanvas-toggler - END --> \ No newline at end of file diff --git a/themes/finc/templates/RecordDriver/DefaultRecord/record-icon.phtml b/themes/finc/templates/RecordDriver/DefaultRecord/record-icon.phtml index 5ce60b63ebc93954de56d1abf763f20fb7a47fd2..b1326e3298090c15549f19039220c98795e1a4d3 100644 --- a/themes/finc/templates/RecordDriver/DefaultRecord/record-icon.phtml +++ b/themes/finc/templates/RecordDriver/DefaultRecord/record-icon.phtml @@ -1,3 +1,4 @@ +<!-- finc: recordDriver - DefaultRecord - record-icon --> <?php /* finc: template is identical with de_15 #13704 - VE */ @@ -26,3 +27,4 @@ if ($this->driver->getRecordType() == "marcfincpda") { <i class="fa <?=$iconClass?>"></i> <span class="hidden-xs"> <?=$this->transEsc("$this->escapeHtml($iconClass)")?></span> </span> +<!-- finc: recordDriver - DefaultRecord - record-icon - END --> diff --git a/themes/finc/templates/RecordDriver/DefaultRecord/result-list.phtml b/themes/finc/templates/RecordDriver/DefaultRecord/result-list.phtml index eee160743c41d6208d14a8a62ce7440bd7b72e18..0a278226b22553f57def57ca00dcd66948fb8808 100644 --- a/themes/finc/templates/RecordDriver/DefaultRecord/result-list.phtml +++ b/themes/finc/templates/RecordDriver/DefaultRecord/result-list.phtml @@ -208,8 +208,8 @@ $i = 0; <?php if ($this->userlist()->getMode() !== 'disabled'): ?> <?php if ($this->permission()->allowDisplay('feature.Favorites')): ?> <?php /* Add to favorites; finc: keep Icon inside link - CK */ ?> - <a href="<?=$this->recordLink()->getActionUrl($this->driver, 'Save')?>" data-lightbox class="save-record result-link-label" data-id="<?=$this->escapeHtmlAttr($this->driver->getUniqueId())?>" title="<?=$this->transEsc('Add to favorites')?>"> - <i class="fa fa-fw fa-star" aria-hidden="true"></i> <span class="hidden-xs hidden-sm"><?=$this->transEsc('Add to favorites')?></span> + <a href="<?=$this->recordLink()->getActionUrl($this->driver, 'Save')?>" data-lightbox class="save-record result-link-label" data-id="<?=$this->escapeHtmlAttr($this->driver->getUniqueId())?>" aria-label="<?=$this->transEsc('Add to favorites')?>"> + <i class="fa fa-fw fa-star" aria-hidden="true"></i> <span><?=$this->transEsc('Add to favorites')?></span> </a><br/> <?php elseif ($block = $this->permission()->getAlternateContent('feature.Favorites')): ?> <?=$block?> diff --git a/themes/finc/templates/RecordDriver/DefaultRecord/toolbar.phtml b/themes/finc/templates/RecordDriver/DefaultRecord/toolbar.phtml index 858a24f8783b40d56c0cbbe5f69109f72c42152e..c0fc17e570ab08f18652ee12ae312c10a5702733 100644 --- a/themes/finc/templates/RecordDriver/DefaultRecord/toolbar.phtml +++ b/themes/finc/templates/RecordDriver/DefaultRecord/toolbar.phtml @@ -1,71 +1,67 @@ <!-- finc: recordDriver - DefaultRecord - toolbar --> <?php -$addThis = $this->addThis(); -if (!empty($addThis)) { - $this->headScript()->appendFile('https://s7.addthis.com/js/250/addthis_widget.js?pub=' . urlencode($addThis)); -} - -// Set up some variables for convenience: -$cart = $this->cart(); -$cartId = $this->driver->getSourceIdentifier() . '|' . $this->driver->getUniqueId(); + $addThis = $this->addThis(); + if (!empty($addThis)) { + $this->headScript()->appendFile('https://s7.addthis.com/js/250/addthis_widget.js?pub=' . urlencode($addThis)); + } + + // Set up some variables for convenience: + $cart = $this->cart(); + $cartId = $this->driver->getSourceIdentifier() . '|' . $this->driver->getUniqueId(); ?> <?php /* finc: add toggler-off button, CK */ ?> -<button class="close-offcanvas btn btn-primary" data-toggle="offcanvas"><?=$this->transEsc('navigate_back') ?></button> +<button class="close-offcanvas btn btn-primary" data-toggle="offcanvas"><?= $this->transEsc('navigate_back') ?></button> <?php /* finc: we use the sr-only description, CK */ ?> -<h2 class="sr-only"><?=$this->transEsc('Toolbar')?></h2> +<h2 class="sr-only"><?= $this->transEsc('Toolbar') ?></h2> <?php /* finc: we use nav-stacked for display in sidebar, CK */ ?> -<ul class="record-nav nav nav-pills nav-stacked hidden-print" aria-label="<?=$this->transEsc('ajaxview_label_tools'); ?>"> - <?php if (count($this->driver->getCitationFormats()) > 0): ?> - <li> - <a class="cite-record" data-lightbox href="<?=$this->recordLink()->getActionUrl($this->driver, 'Cite')?>" rel="nofollow"><i class="fa fa-asterisk" aria-hidden="true"></i> <?=$this->transEsc('Cite this')?></a> - </li> - <?php endif; ?> - <?php /* finc: we don't use sms, CK */ - /* - <?php if ($this->accountCapabilities()->getSmsSetting() !== 'disabled'): ?> - <li><a class="sms-record" data-lightbox href="<?=$this->recordLink()->getActionUrl($this->driver, 'SMS')?>" rel="nofollow"><i class="fa fa-mobile" aria-hidden="true"></i> <?=$this->transEsc('Text this')?></a></li> - <?php endif; ?> - */ ?> - <li> - <a class="mail-record" data-lightbox href="<?=$this->recordLink()->getActionUrl($this->driver, 'Email')?>" rel="nofollow"><i class="fa fa-envelope" aria-hidden="true"></i> <?=$this->transEsc('Email this')?></a> - </li> - - <?php $exportFormats = $this->export()->getFormatsForRecord($this->driver); ?> - <?php if (count($exportFormats) > 0): ?> - <li class="dropdown"> - <a class="export-toggle dropdown-toggle" data-toggle="dropdown" href="<?=$this->recordLink()->getActionUrl($this->driver, 'Export')?>" rel="nofollow" aria-haspopup="true" aria-expanded="false" aria-controls="export-options" id="export-record"><i class="fa fa-list-alt" aria-hidden="true"></i> <?=$this->transEsc('Export Record')?> - </a> - <ul class="dropdown-menu" id="export-options" role="menu"> - <?php foreach ($exportFormats as $exportFormat): ?> - <li role="none"> - <a <?php if ($this->export()->needsRedirect($exportFormat)): ?>target="<?=$this->escapeHtmlAttr($exportFormat)?>Main" <?php endif; ?>href="<?=$this->recordLink()->getActionUrl($this->driver, 'Export')?>?style=<?=$this->escapeHtmlAttr($exportFormat)?>" rel="nofollow" role="menuitem"> - <?=$this->transEsc('Export to')?><?=$this->transEsc($this->export()->getLabelForFormat($exportFormat))?> - </a> - </li> - <?php endforeach; ?> - </ul> - </li> - <?php endif; ?> - - <?php if ($this->userlist()->getMode() !== 'disabled'): ?> - <?php /* finc: we use title=... in link below, CK */ ?> - <li> - <?php if ($this->permission()->allowDisplay('feature.Favorites')): ?> - <a class="save-record" data-lightbox href="<?=$this->recordLink()->getActionUrl($this->driver, 'Save')?>" title="<?=$this->transEsc('Add to favorites')?>" rel="nofollow"><i class="fa fa-star" aria-hidden="true"></i> <?=$this->transEsc('Add to favorites')?> - </a> - <?php elseif ($block = $this->permission()->getAlternateContent('feature.Favorites')): ?> - <?=$block?> +<nav class="record-nav hidden-print"> + <ul class="nav nav-pills nav-stacked hidden-print" aria-label="<?= $this->transEsc('ajaxview_label_tools'); ?>"> + <?php if (count($this->driver->getCitationFormats()) > 0): ?> + <li role="none"><a class="cite-record" data-lightbox href="<?= $this->recordLink()->getActionUrl($this->driver, 'Cite') ?>" rel="nofollow"><i class="fa fa-asterisk" aria-hidden="true"></i> <?= $this->transEsc('Cite this') ?></a></li> + <?php endif; ?> + <?php /* finc: we don't use sms, CK */ + /* + <?php if ($this->accountCapabilities()->getSmsSetting() !== 'disabled'): ?> + <li role="none"><a class="sms-record" data-lightbox href="<?=$this->recordLink()->getActionUrl($this->driver, 'SMS')?>" rel="nofollow"><i class="fa fa-mobile" aria-hidden="true"></i> <?=$this->transEsc('Text this')?></a></li> <?php endif; ?> + */ ?> + <li role="none"><a class="mail-record" data-lightbox href="<?= $this->recordLink()->getActionUrl($this->driver, 'Email') ?>" rel="nofollow"><i class="fa fa-envelope" aria-hidden="true"></i> <?= $this->transEsc('Email this') ?></a></li> + + <?php $exportFormats = $this->export()->getFormatsForRecord($this->driver); ?> + <?php if (count($exportFormats) > 0): ?> + <li role="none" class="dropdown"> + <a class="export-toggle dropdown-toggle" data-toggle="dropdown" aria-haspopup="true" href="<?= $this->recordLink()->getActionUrl($this->driver, 'Export') ?>" rel="nofollow" aria-expanded="false" aria-controls="export-options"><i class="fa fa-list-alt" aria-hidden="true"></i> <?= $this->transEsc('Export Record') ?></a> + <ul class="dropdown-menu" id="export-options" role="menu"> + <?php foreach ($exportFormats as $exportFormat): ?> + <li role="none"> + <a <?php if ($this->export()->needsRedirect($exportFormat)): ?>target="<?= $this->escapeHtmlAttr($exportFormat) ?>Main" + <?php endif; ?>href="<?= $this->recordLink()->getActionUrl($this->driver, 'Export') ?>?style=<?= $this->escapeHtmlAttr($exportFormat) ?>" rel="nofollow" role="menuitem"> + <?= $this->transEsc('Export to') ?><?= $this->transEsc($this->export()->getLabelForFormat($exportFormat)) ?> + </a> + </li> + <?php endforeach; ?> + </ul> + </li> + <?php endif; ?> + + <?php if ($this->userlist()->getMode() !== 'disabled'): ?> + <?php /* finc: we use title=... in link below, CK */ ?> + <li role="none"> + <?php if ($this->permission()->allowDisplay('feature.Favorites')): ?> + <a class="save-record" data-lightbox href="<?= $this->recordLink()->getActionUrl($this->driver, 'Save') ?>" rel="nofollow"><i class="fa fa-star" aria-hidden="true"></i> <?= $this->transEsc('Add to favorites') ?> + </a> + <?php elseif ($block = $this->permission()->getAlternateContent('feature.Favorites')): ?> + <?= $block ?> + <?php endif; ?> + </li> + <?php endif; ?> + <?php if (!empty($addThis)): ?> + <li role="none"><a class="addThis addthis_button" href="https://www.addthis.com/bookmark.php?v=250&pub=<?= urlencode($addThis) ?>"><i class="fa fa-bookmark" aria-hidden="true"></i> <?= $this->transEsc('Bookmark') ?></a></li> + <?php endif; ?> + <li role="none" class="bookbag-menu"> + <?= $this->render('record/cart-buttons.phtml', ['id' => $this->driver->getUniqueId(), 'source' => $this->driver->getSourceIdentifier()]); ?> </li> - <?php endif; ?> - <?php if (!empty($addThis)): ?> - <li> - <a class="addThis addthis_button" href="https://www.addthis.com/bookmark.php?v=250&pub=<?=urlencode($addThis)?>"><i class="fa fa-bookmark" aria-hidden="true"></i> <?=$this->transEsc('Bookmark')?></a> - </li> - <?php endif; ?> - <li class="bookbag-menu"> - <?=$this->render('record/cart-buttons.phtml', ['id' => $this->driver->getUniqueId(), 'source' => $this->driver->getSourceIdentifier()]);?> - </li> -</ul> + </ul> +</nav> <!-- finc: recordDriver - DefaultRecord - toolbar - END --> diff --git a/themes/finc/templates/RecordDriver/SolrAI/data-jTitle.phtml b/themes/finc/templates/RecordDriver/SolrAI/data-jTitle.phtml deleted file mode 100644 index 3d22ec4d5be98a477657be64e84d2a39267f2184..0000000000000000000000000000000000000000 --- a/themes/finc/templates/RecordDriver/SolrAI/data-jTitle.phtml +++ /dev/null @@ -1,35 +0,0 @@ -<!-- finc: RecordDriver - SolrAI - data-jTitle --> -<?php $jtitle = []; ?> -<?php if (!(empty($data))): ?> - <?php $issns = $this->driver->tryMethod('getISSNs'); ?> - <?php ob_start(); ?> - <?php if (!empty($issns)): ?> - <a href="<?=$this->record($this->driver)->getLink('isn', $issns)?>"> - <?=$this->escapeHtml($data)?> - </a> - <?php else: ?> - <?=$this->escapeHtml($data)?> - <?php endif; ?> - <?php - $jtitle[] = trim(preg_replace('/\s+<\//', '</', ob_get_contents())); - ob_end_clean(); - ?> -<?php endif; ?> -<?php -// please note: direction of iteration will be displayed -$methods = ['getVolume', 'getPublishDateSort', 'getIssues', 'getPages']; -foreach ($methods as $method) { - if (!(empty($retval = $this->driver->tryMethod($method)))) { - $jtitle[] = ($method == 'getPages') - ? $this->transEsc('p.') . ' ' . $this->escapeHtml($retval) - : $this->escapeHtml($retval); - } -} -?> -<?php /* finc: add schema tags for parent publication #13850 - VE */ ?> -<span property="isPartOf" typeof="Periodical" resource="#periodical"> - <span property="name"> - <?=implode(', ', $jtitle)?> - </span> -</span> -<!-- finc: RecordDriver - SolrAi - data-jTitle - END --> diff --git a/themes/finc/templates/RecordTab/hierarchytree.phtml b/themes/finc/templates/RecordTab/hierarchytree.phtml index 92eed2720a749b8b8060a87e46c6edf7f182837a..abb953965e0e15919745af3b3a2bc1257105e5fd 100644 --- a/themes/finc/templates/RecordTab/hierarchytree.phtml +++ b/themes/finc/templates/RecordTab/hierarchytree.phtml @@ -27,14 +27,9 @@ <?php foreach ($hierarchyTreeList as $hierarchy => $hierarchyTitle): ?> <?php if($activeTree == $hierarchy): ?> - <span class="item"> - <i class="fa fa-sitemap text-muted" aria-hidden="true"></i> <?=$this->escapeHtml($hierarchyTitle)?> - </span> + <i class="fa fa-sitemap" aria-hidden="true"></i> <?=$this->escapeHtml($hierarchyTitle)?> <?php else: ?> - <span class="item"> - <i class="fa fa-sitemap" aria-hidden="true"></i> - <a href="<?=$this->recordLink()->getTabUrl($this->driver, 'HierarchyTree')?>?hierarchy=<?=urlencode($hierarchy)?>"><?=$this->escapeHtml($hierarchyTitle)?></a> - </span> + <i class="fa fa-sitemap text-muted" aria-hidden="true"></i> <a href="<?=$this->recordLink()->getTabUrl($this->driver, 'HierarchyTree')?>?hierarchy=<?=urlencode($hierarchy)?>"><?=$this->escapeHtml($hierarchyTitle)?></a> <?php endif; ?> <?php endforeach; ?> </div> diff --git a/themes/finc/templates/RecordTab/holdingsils.phtml b/themes/finc/templates/RecordTab/holdingsils.phtml index 5798e8fd6836827582a667a6225c4e9466d124f6..f2788c10708ecb7d90c825df1723e21e5fe952a5 100644 --- a/themes/finc/templates/RecordTab/holdingsils.phtml +++ b/themes/finc/templates/RecordTab/holdingsils.phtml @@ -89,7 +89,7 @@ if (!empty($holdingTitleHold)): ?> <?php foreach ($holdings['holdings'] ?? [] as $holding): ?> <?php /* nxt line = finc-specific - #7841@56988450 - CK */ ?> <?php $holdingsEmpty = false; ?> - <?php /* this next line produces an empty h3 heading in some cases - should be solved more elegantly - Fixme - CK */ ?> + <?php /* this next line produces an empty h2 heading in some cases - should be solved more elegantly - Fixme - CK */ ?> <h2> <?php $locationText = $this->transEsc('location_' . $holding['location'], [], $holding['location']); ?> <?php if (isset($holding['locationhref']) && $holding['locationhref']): ?> @@ -103,7 +103,8 @@ if (!empty($holdingTitleHold)): ?> <?php if (isset($holding['locationid'])): ?> <?=$this->branchInfo($this->driver)->getBranchInfo($holding['locationid']);?> <?php endif; ?> - <?php /* finc: this next section produces an empty table in some cases - the table borders collapse, producing a thick line - should be solved more elegantly - Fixme - , include responsive data table - CK */ ?> + <?php /* finc: this next section produces an empty table in some cases - the table borders collapse, producing a thick line - should be solved more elegantly - Fixme. + include responsive data table - CK */ ?> <table class="table table-striped table-resp-data"> <caption class="sr-only"><?=$this->transEsc('holdings_details_from', ['%%location%%' => $this->transEsc($holding['location'])])?></caption> <?php /* finc: change order and structure of table #13606 - VE */ ?> @@ -124,7 +125,7 @@ if (!empty($holdingTitleHold)): ?> } ?> <?php endforeach; ?> - <? /* finc: we use call numbers in the table after "Notes" + <?php /* finc: we use call numbers in the table after "Notes" We don't use the links to alphabrowse - CK */ ?> <?php $callNos = $this->tab->getUniqueCallNumbers($holding['items']); if (!empty($callNos)): ?> <tr> @@ -133,7 +134,11 @@ if (!empty($holdingTitleHold)): ?> </th> <td data-title="<?= $this->transEsc("Call Number") ?>:"> <?php foreach ($callNos as $callNo): ?> + <?php if ($this->callnumberHandler): ?> + <a href="<?=$this->url('alphabrowse-home') ?>?source=<?=$this->escapeHtmlAttr($this->callnumberHandler) ?>&from=<?=$this->escapeHtmlAttr($callNo) ?>"><?=$this->escapeHtml($callNo)?></a> + <?php else: ?> <?=$this->escapeHtml($callNo)?> + <?php endif; ?> <br /> <?php endforeach; ?> </td> diff --git a/themes/finc/templates/RecordTab/holdingsils/standard.phtml b/themes/finc/templates/RecordTab/holdingsils/standard.phtml index 9842a0a0d71e69e3e6b605d07d1a98760a3a4b63..561d2f01b1e944b7cbb1223556f6624f76eaedb6 100644 --- a/themes/finc/templates/RecordTab/holdingsils/standard.phtml +++ b/themes/finc/templates/RecordTab/holdingsils/standard.phtml @@ -1,110 +1,114 @@ <!-- finc - recordtab - holdingsils - standard --> <?php /* This is a new file introduced in VF5 -- it originated from the old holdingsils file, for history, check there, CK */ ?> <?php if (strlen($holding['barcode'] ?? '') > 0): ?> -<?php + <?php $check = $holding['check'] ?? false; $checkStorageRetrievalRequest = $holding['checkStorageRetrievalRequest'] ?? false; $checkILLRequest = $holding['checkILLRequest'] ?? false; // finc: nxt line - emailholds #6096 - CK $checkEmailHold = (isset($holding['checkEmailHold']) && $holding['checkEmailHold']); -?> -<tr vocab="http://schema.org/" typeof="Offer"> - <?php /* finc: remove transEsc("Copy") and number from TH, #13606 - VE */ /* + ?> + <tr vocab="http://schema.org/" typeof="Offer"> + <?php /* finc: remove transEsc("Copy") and number from TH, #13606 - VE */ /* <th class="copy-number"><?=$this->transEsc("Copy")?> <?=$this->escapeHtml($holding['number'])?> <?php if ($holding['enumchron'] ?? false): ?> <span class="enumchron">(<?=$this->escapeHtml($holding['enumchron'])?>)</span> <?php endif; ?> </th> */ ?> - <td data-title="<?=$this->transEsc('Availability')?>" class="availability-column"> - <?php if ($holding['reserve'] == "Y"): ?> - <link property="availability" href="http://schema.org/InStoreOnly"/> - <?=$this->transEsc("On Reserve - Ask at Circulation Desk")?><br><br> - <?php endif; ?> - <?php if ($holding['use_unknown_message'] ?? false): ?> - <span class="text-muted"><?=$this->transEsc("status_unknown_message")?></span> - <?php else: ?> + <td data-title="<?= $this->transEsc('Availability') ?>" class="availability-column"> + <?php if ($holding['reserve'] == "Y"): ?> + <link property="availability" href="http://schema.org/InStoreOnly"/> + <?= $this->transEsc("On Reserve - Ask at Circulation Desk") ?><br><br> + <?php endif; ?> + <?php if ($holding['use_unknown_message'] ?? false): ?> + <span class="text-muted"><?= $this->transEsc("status_unknown_message") ?></span> + <?php else: ?> <?php if ($holding['availability'] ?? false): ?> <?php /* Begin Available Items (Holds) */ ?> - <span class="text-success"><?=$this->transEsc("Available")?> + <span class="text-success"><?= $this->transEsc("Available") ?> <link property="availability" href="http://schema.org/InStock"/> </span> <?php if ($holding['link'] ?? false): ?> - <?php /* finc: add class .hidden-print + add title, CK */ ?> - <a class="<?=$check ? 'checkRequest ' : ''?>placehold hidden-print" <?php if (!empty($holding['linkLightbox'])): ?>data-lightbox <?php endif; ?>href="<?=$this->recordLink()->getRequestUrl($holding['link'])?>" title="<?=$this->transEsc($check ? "Check Hold" : "Place a Hold")?>"><i class="fa fa-flag" aria-hidden="true"></i> <?=$this->transEsc($check ? "Check Hold" : "Place a Hold")?> - </a> - <?php endif; ?> + <?php /* finc: add class .hidden-print CK */ ?> + <a class="<?= $check ? 'checkRequest ' : '' ?>placehold hidden-print" <?php if (!empty($holding['linkLightbox'])): ?>data-lightbox <?php endif; ?>href="<?= $this->recordLink()->getRequestUrl($holding['link']) ?>"> + <i class="fa fa-flag" aria-hidden="true"></i> <?= $this->transEsc($check ? "Check Hold" : "Place a Hold") ?> + </a> + <?php endif; ?> <?php if ($holding['storageRetrievalRequestLink'] ?? false): ?> - <a class="<?=$checkStorageRetrievalRequest ? 'checkStorageRetrievalRequest ' : ''?> placeStorageRetrievalRequest" data-lightbox href="<?=$this->recordLink()->getRequestUrl($holding['storageRetrievalRequestLink'])?>"><i class="fa fa-flag" aria-hidden="true"></i> <?=$this->transEsc($checkStorageRetrievalRequest ? "storage_retrieval_request_check_text" : "storage_retrieval_request_place_text")?> - </a> - <?php endif; ?> + <a class="<?= $checkStorageRetrievalRequest ? 'checkStorageRetrievalRequest ' : '' ?> placeStorageRetrievalRequest" data-lightbox href="<?= $this->recordLink()->getRequestUrl($holding['storageRetrievalRequestLink']) ?>"> + <i class="fa fa-flag" aria-hidden="true"></i> <?= $this->transEsc($checkStorageRetrievalRequest ? "storage_retrieval_request_check_text" : "storage_retrieval_request_place_text") ?> + </a> + <?php endif; ?> <?php if ($holding['ILLRequestLink'] ?? false): ?> - <a class="<?=$checkILLRequest ? 'checkILLRequest ' : ''?>placeILLRequest" data-lightbox href="<?=$this->recordLink()->getRequestUrl($holding['ILLRequestLink'])?>"><i class="fa fa-flag" aria-hidden="true"></i> <?=$this->transEsc($checkILLRequest ? "ill_request_check_text" : "ill_request_place_text")?> - </a> + <a class="<?= $checkILLRequest ? 'checkILLRequest ' : '' ?>placeILLRequest" data-lightbox href="<?= $this->recordLink()->getRequestUrl($holding['ILLRequestLink']) ?>"> + <i class="fa fa-flag" aria-hidden="true"></i> <?= $this->transEsc($checkILLRequest ? "ill_request_check_text" : "ill_request_place_text") ?> + </a> <?php endif; ?> <?php /* finc-specific additional insert, newspaper orders via mail - #6096 - CK */ ?> <?php if (isset($holding['emailHoldLink']) && $holding['emailHoldLink']): ?> - <a class="<?=$checkEmailHold ? 'checkEmailHold ' : ''?>placeEmailHold " data-lightbox href="<?=$this->recordLink()->getRequestUrl($holding['emailHoldLink'])?>" title="<?=$this->transEsc($checkEmailHold ? "EmailHold::email_hold_check_text" : "EmailHold::email_hold_place_text")?>"><i class="fa fa-flag"></i> <?=$this->transEsc($checkEmailHold ? "EmailHold::email_hold_check_text" : "EmailHold::email_hold_place_text")?></a> + <a class="<?= $checkEmailHold ? 'checkEmailHold ' : '' ?>placeEmailHold " data-lightbox href="<?= $this->recordLink()->getRequestUrl($holding['emailHoldLink']) ?>" title="<?= $this->transEsc($checkEmailHold ? "EmailHold::email_hold_check_text" : "EmailHold::email_hold_place_text") ?>"> + <i class="fa fa-flag"></i> <?= $this->transEsc($checkEmailHold ? "EmailHold::email_hold_check_text" : "EmailHold::email_hold_place_text") ?> + </a> <?php endif; ?> <? /* finc-specific insert - #6096 - END */ ?> <?php else: ?> <?php /* Begin Unavailable Items (Recalls) */ ?> <?php /* finc: use empty status and transEsc 'Unavailable', CK */ ?> - <span class="text-danger"><?=empty($holding['status']) ? $this->transEsc("Unavailable") : $this->transEsc($holding['status'])?> <link property="availability" href="http://schema.org/OutOfStock"/> - </span> - <?php if ($holding['returnDate'] ?? false): ?>– <span><?=$this->escapeHtml($holding['returnDate'])?></span><?php endif; ?> + <span class="text-danger"><?= empty($holding['status']) ? $this->transEsc("Unavailable") : $this->transEsc($holding['status']) ?> <link property="availability" href="http://schema.org/OutOfStock"/></span> + <?php if ($holding['returnDate'] ?? false): ?>– <span><?= $this->escapeHtml($holding['returnDate']) ?></span><?php endif; ?> <?php if ($holding['duedate'] ?? false): ?> - <?php /* finc: keep nbsp + ndash or due date text will bump into alert, CK */ ?> - – <span><?=$this->transEsc("Due")?>: <?=$this->escapeHtml($holding['duedate'])?></span> - <?php endif; ?> + <?php /* finc: keep nbsp + ndash or due date text will bump into alert, CK */ ?> + – <span><?= $this->transEsc("Due") ?>: <?= $this->escapeHtml($holding['duedate']) ?></span> + <?php endif; ?> <?php if (($holding['requests_placed'] ?? 0) > 0): ?> - <span><?=$this->transEsc("Requests")?>: <?=$this->escapeHtml($holding['requests_placed'])?></span> - <?php endif; ?> + <span><?= $this->transEsc("Requests") ?>: <?= $this->escapeHtml($holding['requests_placed']) ?></span> + <?php endif; ?> <?php if ($holding['link'] ?? false): ?> - <a class="<?=$check ? 'checkRequest' : ''?> placehold" <?php if (!empty($holding['linkLightbox'])): ?>data-lightbox - <?php endif; ?>href="<?=$this->recordLink()->getRequestUrl($holding['link'])?>"><i class="fa fa-flag" - aria-hidden="true"></i> <?=$this->transEsc($check ? "Check Recall" : "Recall This")?></a> + <a class="<?= $check ? 'checkRequest' : '' ?> placehold" <?php if (!empty($holding['linkLightbox'])): ?>data-lightbox <?php endif; ?>href="<?= $this->recordLink()->getRequestUrl($holding['link']) ?>"> + <i class="fa fa-flag" aria-hidden="true"></i> <?= $this->transEsc($check ? "Check Recall" : "Recall This") ?> + </a> + <?php endif; ?> + <?= $this->relais()->renderButtonIfActive($this->driver ?? null) ?> + <?php endif; ?> + </td> + <td data-title="<?= $this->transEsc('Notes') ?>" class="notes"> + <?php if (isset($holding['item_notes'])): ?> + <div class="item-notes"> + <strong><?= $this->transEsc("Item Notes") ?>:</strong> + <ul> + <?php foreach ($holding['item_notes'] as $item_note): ?> + <li><?= $this->escapeHtml($item_note) ?></li> + <?php endforeach; ?> + </ul> + </div> + <?php endif; ?> + <?php endif; ?> + <?php /* Embed item structured data: library, barcode, call number */ ?> + <?php if ($holding['location'] ?? false): ?> + <meta property="seller" content="<?= $this->escapeHtmlAttr($holding['location']) ?>"/> <?php endif; ?> - <?=$this->relais()->renderButtonIfActive($this->driver ?? null)?> + <?php if ($holding['barcode'] ?? false): ?> + <meta property="serialNumber" content="<?= $this->escapeHtmlAttr($holding['barcode']) ?>"/> <?php endif; ?> - </td> - <td data-title="<?=$this->transEsc('Notes')?>" class="notes"> - <?php if (isset($holding['item_notes'])): ?> - <div class="item-notes"> - <strong><?=$this->transEsc("Item Notes")?>:</strong> - <ul> - <?php foreach ($holding['item_notes'] as $item_note): ?> - <li><?=$this->escapeHtml($item_note)?></li> - <?php endforeach; ?> - </ul> - </div> + <?php if ($holding['callnumber'] ?? false): ?> + <meta property="sku" content="<?= $this->escapeHtmlAttr($holding['callnumber']) ?>"/> <?php endif; ?> - <?php endif; ?> - <?php /* Embed item structured data: library, barcode, call number */ ?> - <?php if ($holding['location'] ?? false): ?> - <meta property="offeredBy" content="<?=$this->escapeHtmlAttr($holding['location'])?>"/> - <?php endif; ?> - <?php if ($holding['barcode'] ?? false): ?> - <meta property="serialNumber" content="<?=$this->escapeHtmlAttr($holding['barcode'])?>"/> - <?php endif; ?> - <?php if ($holding['callnumber'] ?? false): ?> - <meta property="sku" content="<?=$this->escapeHtmlAttr($holding['callnumber'])?>"/> - <?php endif; ?> - <?php /* Declare that the item is to be borrowed, not for sale */ ?> - <link property="businessFunction" href="http://purl.org/goodrelations/v1#LeaseOut"/> - <link property="itemOffered" href="#record"/> - <?php /* finc: price tags can be anywhere but seem to be required for product */ ?> - <meta property="price" content="0"> - <meta property="priceCurrency" content="€"> - - <?php if (isset($holding['textfields'])): foreach ($holding['textfields'] as $textFieldName => $textFields): ?> - <span> + <?php /* Declare that the item is to be borrowed, not for sale */ ?> + <link property="businessFunction" href="http://purl.org/goodrelations/v1#LeaseOut"/> + <link property="itemOffered" href="#record"/> + <?php /* finc: price tags can be anywhere but seem to be required for product */ ?> + <meta property="price" content="0"> + <meta property="priceCurrency" content="€"> + + <?php if (isset($holding['textfields'])): foreach ($holding['textfields'] as $textFieldName => $textFields): ?> + <span> <?php foreach ($textFields as $current): ?> - <?=$textFieldName == 'summary' ? $this->transEsc("Volume Holdings") : $this->transEsc(ucfirst($textFieldName))?>: <?=$this->escapeHtml($current)?><br/> - <?php endforeach; ?> + <?= $textFieldName == 'summary' ? $this->transEsc("Volume Holdings") : $this->transEsc(ucfirst($textFieldName)) ?>: <?= $this->escapeHtml($current) ?><br/> + <?php endforeach; ?> </span> - <?php endforeach; endif; ?> - </td> -</tr> + <?php endforeach; endif; ?> + </td> + </tr> <?php endif; ?> <!-- finc - recordtab - holdingsils - standard - END --> diff --git a/themes/finc/templates/RecordTab/staffviewmarc.phtml b/themes/finc/templates/RecordTab/staffviewmarc.phtml index d18b65df2ed387b567fabe29577c5eedc0979e7a..ebd800bbd7d5e6d2d6ed8fbd27770e893a99748a 100644 --- a/themes/finc/templates/RecordTab/staffviewmarc.phtml +++ b/themes/finc/templates/RecordTab/staffviewmarc.phtml @@ -6,12 +6,14 @@ $this->headTitle($this->translate('Staff View') . ': ' . $this->driver->getBread <?=\VuFind\XSLT\Processor::process('record-marc.xsl', $this->driver->getXML('marc21'))?> <?php /* the following introduced in 9934*/ ?> <?php if ($openURL = $this->driver->getOpenUrl()): ?> - <tr> - <th><?=$this->escapeHtml('openURL')?></th> - <td data-title="<?= $this->escapeHtml('openURL') ?>:"> - <?=$this->escapeHtml($openURL)?><br/> - </td> - </tr> + <table> + <tr> + <th><?=$this->escapeHtml('openURL')?></th> + <td data-title="<?= $this->escapeHtml('openURL') ?>:"> + <?=$this->escapeHtml($openURL)?><br/> + </td> + </tr> + </table> <?php endif; ?> <?php $fields = $this->driver->getRawData(); if (!empty($fields)): ?> diff --git a/themes/finc/templates/admin/menu.phtml b/themes/finc/templates/admin/menu.phtml index a87d2a3c8a785e10d04348d1c50f6c1b0a706fa9..2b836e3b620230d830926556eac44e23d4f87471 100644 --- a/themes/finc/templates/admin/menu.phtml +++ b/themes/finc/templates/admin/menu.phtml @@ -4,5 +4,6 @@ <a href="<?=$this->url('admin/config')?>" class="list-group-item<?=strtolower($this->layout()->templateName) == "config" ? ' active' : ''?>"><?=$this->transEsc('Configuration')?></a> <a href="<?=$this->url('admin/maintenance')?>" class="list-group-item<?=strtolower($this->layout()->templateName) == "maintenance" ? ' active' : ''?>"><?=$this->transEsc('System Maintenance')?></a> <a href="<?=$this->url('admin/tags')?>" class="list-group-item<?=strtolower($this->layout()->templateName) == "tags" ? ' active' : ''?>"><?=$this->transEsc('Tag Maintenance')?></a> + <?php /* finc-specific: translation admin */ ?> <a href="<?=$this->url('admin/i18n')?>" class="list-group-item<?=strtolower($this->layout()->templateName) == "tags" ? ' active' : ''?>"><?=$this->transEsc('admin_i18n_menu_entry')?></a> </div> diff --git a/themes/finc/templates/alphabrowse/home.phtml b/themes/finc/templates/alphabrowse/home.phtml index 4fb26be322bbb8f967c2fce2b2d0e67187d127c3..0e024ed7736b62ce650b2ecb94301eaa95c34525 100644 --- a/themes/finc/templates/alphabrowse/home.phtml +++ b/themes/finc/templates/alphabrowse/home.phtml @@ -20,15 +20,25 @@ <?php ob_start(); ?> <ul class="pager"> <?php if (isset($this->prevpage)): ?> - <li><a href="<?=$this->escapeHtmlAttr($this->url('alphabrowse-home', [], ['query' => $baseQuery + ['page' => $this->prevpage]]))?>"><span aria-hidden="true">«</span> <?=$this->transEsc('Prev')?></a></li> + <li> + <a href="<?=$this->escapeHtmlAttr($this->url('alphabrowse-home', [], ['query' => $baseQuery + ['page' => $this->prevpage]]))?>" aria-label="<?=$this->transEsc('page_prev')?>"> + <i class="fa fa-angle-left" aria-hidden="true"></i> + <?=$this->transEsc('Prev')?> + </a> + </li> <?php else: ?> - <li class="disabled"><a href="#"><span aria-hidden="true">«</span> <?=$this->transEsc('Prev')?></a></li> + <li class="disabled" aria-hidden="true"><i class="fa fa-angle-left" aria-hidden="true"></i> <?=$this->transEsc('Prev')?></li> <?php endif; ?> <?php if (isset($this->nextpage)): ?> - <li><a href="<?=$this->escapeHtmlAttr($this->url('alphabrowse-home', [], ['query' => $baseQuery + ['page' => $this->nextpage]]))?>"><?=$this->transEsc('Next')?> <span aria-hidden="true">»</span></a></li> + <li> + <a href="<?=$this->escapeHtmlAttr($this->url('alphabrowse-home', [], ['query' => $baseQuery + ['page' => $this->nextpage]]))?>" aria-label="<?=$this->transEsc('page_next')?>"> + <?=$this->transEsc('Next')?> + <i class="fa fa-angle-right" aria-hidden="true"></i> + </a> + </li> <?php else: ?> - <li class="disabled"><a href="#"><?=$this->transEsc('Next')?> <span aria-hidden="true">»</span></a></li> + <li class="disabled" aria-hidden="true"><?=$this->transEsc('Next')?> <i class="fa fa-angle-right" aria-hidden="true"></i></li> <?php endif; ?> </ul> <?php $pageLinks = ob_get_contents(); ?> diff --git a/themes/finc/templates/cart/cart.phtml b/themes/finc/templates/cart/cart.phtml index 18640d73b2c1db25322f9d55d6f0c8897a34c485..7ac208d9e771e3d811ae9d85a734363d7bf9ab7f 100644 --- a/themes/finc/templates/cart/cart.phtml +++ b/themes/finc/templates/cart/cart.phtml @@ -20,22 +20,22 @@ </label> </div> <?php if ($this->userlist()->getMode() !== 'disabled'): ?> - <button type="submit" class="btn btn-transparent" name="saveCart" title="<?=$this->transEsc('bookbag_save')?>" value="1"> + <button type="submit" class="btn btn-transparent" name="saveCart" value="1"> <i class="fa fa-save" aria-hidden="true"></i> <?=$this->transEsc('Save')?> </button> <?php endif; ?> - <button type="submit" class="btn btn-transparent" name="email" title="<?=$this->transEsc('bookbag_email')?>" value="1"> + <button type="submit" class="btn btn-transparent" name="email" value="1"> <i class="fa fa-envelope-o" aria-hidden="true"></i> <?=$this->transEsc('Email')?> </button> <?php $exportOptions = $this->export()->getActiveFormats('bulk'); if (count($exportOptions) > 0): ?> - <button type="submit" class="btn btn-transparent" name="export" title="<?=$this->transEsc('bookbag_export')?>" value="1"> + <button type="submit" class="btn btn-transparent" name="export" value="1"> <i class="fa fa-list-alt" aria-hidden="true"></i> <?=$this->transEsc('Export')?> </button> <?php endif; ?> - <button type="submit" class="btn btn-transparent dropdown-toggle" name="print" title="<?=$this->transEsc('print_selected')?>" value="1"> + <button type="submit" class="btn btn-transparent dropdown-toggle" name="print" value="1"> <i class="fa fa-printer" aria-hidden="true"></i> <?=$this->transEsc('Print')?> </button> diff --git a/themes/finc/templates/collection/view.phtml b/themes/finc/templates/collection/view.phtml index 14646b9d9dffe2826ea4f0138e4082fc2ba59c2f..057474afed69e6f01dd3e1425f0b714c716d6bff 100644 --- a/themes/finc/templates/collection/view.phtml +++ b/themes/finc/templates/collection/view.phtml @@ -82,7 +82,7 @@ </div> <?php if (isset($activeTabObj) && is_callable([$activeTabObj, 'getSideRecommendations'])): ?> - <div class="<?= $this->layoutClass('sidebar') ?>"> + <div class="<?= $this->layoutClass('sidebar') ?>" id="myresearch-sidebar"> <?php /* pull the toolbar here, finc-specific, CK */ ?> <?= $this->record($this->driver)->getToolbar() ?> diff --git a/themes/finc/templates/header.phtml b/themes/finc/templates/header.phtml index b0cc6784bbac2454fb06f65f257c7f63c8358c67..e277d9d9374976bbd3e34e3f0b88dea27fefbfb2 100644 --- a/themes/finc/templates/header.phtml +++ b/themes/finc/templates/header.phtml @@ -104,13 +104,13 @@ <input type="hidden" name="mylang"/> </form> - <a href="#" class="btn dropdown-toggle <?=(count($this->layout()->allLangs) == 2) ? ' hidden-xs hidden-sm hidden-md hidden-lg' : ''?>" data-toggle="dropdown" aria-controls="langmenu" aria-expanded="false"> + <a href="#" class="btn dropdown-toggle <?=(count($this->layout()->allLangs) == 2) ? ' hidden' : ''?>" data-toggle="dropdown" aria-controls="langmenu" aria-expanded="false"> <?=$this->transEsc("Language")?> <strong class="caret"></strong> </a> <ul id="langmenu" class="dropdown-menu <?=(count($this->layout()->allLangs) == 2) ? ' oneLanguage' : ''?>"> <?php foreach ($this->layout()->allLangs as $langCode => $langName): ?> - <?php if (!(strcmp($langCode, $this->layout()->userLang) == 0)) : ?> + <?php if ($langCode !== $this->layout()->userLang) : ?> <li> <a class="btn <?=(count($this->layout()->allLangs) == 2) ? ' btn-secondary' : ''?>" href="#" onClick="document.langForm.mylang.value='<?=$langCode?>';document.langForm.submit()"><?=$this->displayLanguageOption($langName)?></a> </li> diff --git a/themes/finc/templates/layout/layout.phtml b/themes/finc/templates/layout/layout.phtml index ea1281fba3bbd688f5788ec7ddb8a39cebc1b80b..2db1002ed24142e7b60fbe138a54d0219c5a8090 100644 --- a/themes/finc/templates/layout/layout.phtml +++ b/themes/finc/templates/layout/layout.phtml @@ -164,9 +164,9 @@ if (!isset($this->layout()->searchbox)) { <a class="sr-only" href="#content"><?=$this->transEsc('Skip to content')?></a> <?php if (substr_count(strtolower($this->layout()->templateName), 'results') > 0): ?> <?php if (strcmp($this->layout()->userLang, 'de') == 0): ?> - <a class="sr-only hidden-xs" href="#search-sidebar"><?=$this->transEsc(isset($this->overrideSideFacetCaption) ? $this->overrideSideFacetCaption : 'Narrow Search')?></a> + <a class="sr-only hidden-xs" href="#myresearch-sidebar"><?=$this->transEsc(isset($this->overrideSideFacetCaption) ? $this->overrideSideFacetCaption : 'Narrow Search')?></a> <?php else: ?> - <a class="sr-only hidden-xs" href="#search-sidebar"><?=$this->transEsc('skip-to')?><?=strtolower($this->transEsc(isset($this->overrideSideFacetCaption) ? $this->overrideSideFacetCaption : 'Narrow Search'))?></a> + <a class="sr-only hidden-xs" href="#myresearch-sidebar"><?=$this->transEsc('skip-to')?><?=strtolower($this->transEsc(isset($this->overrideSideFacetCaption) ? $this->overrideSideFacetCaption : 'Narrow Search'))?></a> <?php endif; ?> <?php endif; ?> @@ -203,7 +203,7 @@ if (!isset($this->layout()->searchbox)) { </nav> <div role="main" class="main"> <div id="content" class="container"> - <?=$this->layout()->content?> + <?=$this->layout()->content?> </div> </div> diff --git a/themes/finc/templates/librarycards/editcard.phtml b/themes/finc/templates/librarycards/editcard.phtml index 680361fd6fe5db72ede338b16bfc65ee9eeba030..3bd6a5481027a6d283402970989b1ba2f0f5df08 100644 --- a/themes/finc/templates/librarycards/editcard.phtml +++ b/themes/finc/templates/librarycards/editcard.phtml @@ -1,6 +1,4 @@ <!-- finc - templates - librarycards - editcard --> -<?php /* copied from bootstrap3 - h2 becomes h1 - #17596 - HR */?> - <?php // Set up page title: $pageTitle = empty($this->card->id) ? 'Add a Library Card' : "Edit Library Card"; diff --git a/themes/finc/templates/librarycards/home.phtml b/themes/finc/templates/librarycards/home.phtml index c9935519e9ad9e8597eb3315603557fa44fbc76e..aa272f988dfcc902786529b75be77e73e4fd6931 100644 --- a/themes/finc/templates/librarycards/home.phtml +++ b/themes/finc/templates/librarycards/home.phtml @@ -60,7 +60,7 @@ </div> </div> - <div class="<?=$this->layoutClass('sidebar')?>"> + <div class="<?=$this->layoutClass('sidebar')?>" id="myresearch-sidebar"> <?=$this->context($this)->renderInContext("myresearch/menu.phtml", ['active' => 'librarycards'])?> </div> <!-- find: librarycards - home - END --> diff --git a/themes/finc/templates/myresearch/acquisition.phtml b/themes/finc/templates/myresearch/acquisition.phtml index d75b4c1f66695e9d6438afa076280cbd3dc80d19..ec13fd1bfc84894c2ffde5ab1dab069025486e3f 100644 --- a/themes/finc/templates/myresearch/acquisition.phtml +++ b/themes/finc/templates/myresearch/acquisition.phtml @@ -7,10 +7,11 @@ $this->headTitle($this->translate('PDA::pda_form_title')); $this->layout()->breadcrumbs = '<li><a href="' . $this->url('myresearch-home') . '">' . $this->transEsc('Your Account') . '</a></li> <li class="active">' . $this->transEsc('PDA::pda_form_title') . '</li>'; ?> -<div class="<?=$this->layoutClass('mainbody')?>"> - <?php /* finc V5: toggler was missing, remove entire template (!) when fixed in BS3 theme - CK */ ?> - <?=$this->render('RecordDriver/DefaultRecord/offcanvas-toggler-myresearch'); ?> +<a class="search-filter-toggle visible-xs" href="#myresearch-sidebar" data-toggle="offcanvas" title="Expand Sidebar"> + <?= $this->transEsc('Your Account') ?> +</a> +<div class="<?=$this->layoutClass('mainbody')?>"> <h1><?=$this->transEsc('PDA::pda_form_subtitle')?></h1> <?=$this->flashmessages()?> <form method="post" action="" name="acquisitionForm"> @@ -47,8 +48,8 @@ $this->layout()->breadcrumbs = '<li><a href="' . $this->url('myresearch-home') . </div> </form> </div> -<div class="<?=$this->layoutClass('sidebar')?>"> - <?=$this->context($this)->renderInContext("myresearch/menu.phtml", array('active' => 'aquisition'))?> +<div class="<?= $this->layoutClass('sidebar') ?>" id="myresearch-sidebar"> + <?= $this->context($this)->renderInContext("myresearch/menu.phtml", ['active' => 'profile']) ?> </div> <!-- finc: myresearch - acquisition - END --> diff --git a/themes/finc/templates/myresearch/checkedout.phtml b/themes/finc/templates/myresearch/checkedout.phtml index 0c2a23e6f051b8ec67bf8f47ae189382c0288f72..8c9fb4c8fa7860bf35165a68700a6e7001451a2e 100644 --- a/themes/finc/templates/myresearch/checkedout.phtml +++ b/themes/finc/templates/myresearch/checkedout.phtml @@ -10,10 +10,11 @@ $renewAll = !$this->ilsPaging || !$paginator; ?> -<div class="<?=$this->layoutClass('mainbody')?>"> - <?php /* finc V5: toggler was missing, remove entire template (!) when fixed in BS3 theme - CK */ ?> - <?=$this->render('RecordDriver/DefaultRecord/offcanvas-toggler-myresearch'); ?> +<a class="search-filter-toggle visible-xs" href="#myresearch-sidebar" data-toggle="offcanvas" title="Expand Sidebar"> + <?=$this->transEsc('Your Account') ?> +</a> +<div class="<?=$this->layoutClass('mainbody')?>"> <h1><?=$this->transEsc('Your Checked Out Items')?></h1> <?=$this->flashmessages()?> @@ -209,7 +210,7 @@ <?php endif; ?> </div> -<div class="<?=$this->layoutClass('sidebar')?>"> +<div class="<?=$this->layoutClass('sidebar')?>" id="myresearch-sidebar"> <?=$this->context($this)->renderInContext("myresearch/menu.phtml", ['active' => 'checkedout'])?> </div> <!-- finc: myresearch - checkedout - END --> diff --git a/themes/finc/templates/myresearch/fines.phtml b/themes/finc/templates/myresearch/fines.phtml index 39ca35c02deeed955a7e64351a19f481549a295f..5c840caf85cd396a82dc7183744c506f182eeb14 100644 --- a/themes/finc/templates/myresearch/fines.phtml +++ b/themes/finc/templates/myresearch/fines.phtml @@ -6,10 +6,12 @@ // Set up breadcrumbs: $this->layout()->breadcrumbs = '<li><a href="' . $this->url('myresearch-home') . '">' . $this->transEsc('Your Account') . '</a></li> <li class="active">' . $this->transEsc('Fines') . '</li>'; ?> -<div class="<?=$this->layoutClass('mainbody')?>"> - <?php /* finc V5: toggler was missing, remove entire template (!) when fixed in BS3 theme - CK */ ?> - <?=$this->render('RecordDriver/DefaultRecord/offcanvas-toggler-myresearch'); ?> +<a class="search-filter-toggle visible-xs" href="#myresearch-sidebar" data-toggle="offcanvas" title="Expand Sidebar"> + <?=$this->transEsc('Your Account') ?> +</a> + +<div class="<?=$this->layoutClass('mainbody')?>"> <h1><?=$this->transEsc('Your Fines')?></h1> <?=$this->flashmessages()?> @@ -87,7 +89,7 @@ <?php endif; ?> </div> -<div class="<?=$this->layoutClass('sidebar')?>"> +<div class="<?=$this->layoutClass('sidebar')?>" id="myresearch-sidebar"> <?=$this->context($this)->renderInContext("myresearch/menu.phtml", ['active' => 'fines'])?> </div> <!-- finc: myresearch - fines - END --> diff --git a/themes/finc/templates/myresearch/historicloans.phtml b/themes/finc/templates/myresearch/historicloans.phtml index 47460e73b443c6e2c84187d9b561ee6bc2580dc1..8b713395b0d48a0edae5c227f39fec74ddea76af 100644 --- a/themes/finc/templates/myresearch/historicloans.phtml +++ b/themes/finc/templates/myresearch/historicloans.phtml @@ -7,10 +7,11 @@ $this->layout()->breadcrumbs = '<li><a href="' . $this->url('myresearch-home') . '">' . $this->transEsc('Your Account') . '</a></li> <li class="active">' . $this->transEsc('Loan History') . '</li>'; ?> -<div class="<?=$this->layoutClass('mainbody')?>"> - <?php /* finc V5: toggler was missing, remove entire template (!) when fixed in BS3 theme - CK */ ?> - <?=$this->render('RecordDriver/DefaultRecord/offcanvas-toggler-myresearch'); ?> +<a class="search-filter-toggle visible-xs" href="#myresearch-sidebar" data-toggle="offcanvas" title="Expand Sidebar"> + <?=$this->transEsc('Your Account') ?> +</a> +<div class="<?=$this->layoutClass('mainbody')?>"> <h1><?=$this->transEsc('Loan History')?></h1> <?=$this->flashmessages()?> @@ -130,7 +131,7 @@ <?php endif; ?> </div> -<div class="<?=$this->layoutClass('sidebar')?>"> +<div class="<?=$this->layoutClass('sidebar')?>" id="myresearch-sidebar"> <?=$this->context($this)->renderInContext("myresearch/menu.phtml", ['active' => 'historicloans'])?> </div> <!-- finc: myresearch - historicloans - END --> diff --git a/themes/finc/templates/myresearch/holds.phtml b/themes/finc/templates/myresearch/holds.phtml index f77aa2c25fed7cd4db5536e2e54a7bf8090a1ad3..e837c575c5a9b1e3ce0e52645546dc1421746302 100644 --- a/themes/finc/templates/myresearch/holds.phtml +++ b/themes/finc/templates/myresearch/holds.phtml @@ -7,10 +7,11 @@ $this->layout()->breadcrumbs = '<li><a href="' . $this->url('myresearch-home') . '">' . $this->transEsc('Your Account') . '</a></li> <li class="active">' . $this->transEsc('My Holds') . '</li>'; ?> -<div class="<?=$this->layoutClass('mainbody')?>"> - <?php /* finc V5: toggler was missing, remove entire template (!) when fixed in BS3 theme - CK */ ?> - <?=$this->render('RecordDriver/DefaultRecord/offcanvas-toggler-myresearch'); ?> +<a class="search-filter-toggle visible-xs" href="#myresearch-sidebar" data-toggle="offcanvas" title="Expand Sidebar"> + <?=$this->transEsc('Your Account') ?> +</a> +<div class="<?=$this->layoutClass('mainbody')?>"> <h1><?=$this->transEsc('Your Holds and Recalls') ?></h1> <?=$this->flashmessages()?> @@ -182,7 +183,7 @@ <?php endif; ?> </div> -<div class="<?=$this->layoutClass('sidebar')?>"> +<div class="<?=$this->layoutClass('sidebar')?>" id="myresearch-sidebar"> <?=$this->context($this)->renderInContext("myresearch/menu.phtml", ['active' => 'holds'])?> </div> <!-- finc: myresearch - holds - END --> diff --git a/themes/finc/templates/myresearch/illrequests.phtml b/themes/finc/templates/myresearch/illrequests.phtml index 120e6e614e46f4f6dfdbd00b47c5863548c24d93..26691d254987144ba5104d9d1885b726e72318f2 100644 --- a/themes/finc/templates/myresearch/illrequests.phtml +++ b/themes/finc/templates/myresearch/illrequests.phtml @@ -7,10 +7,12 @@ $this->layout()->breadcrumbs = '<li><a href="' . $this->url('myresearch-home') . '">' . $this->transEsc('Your Account') . '</a></li>' . '<li class="active">' . $this->transEsc('Interlibrary Loan Requests') . '</li>'; ?> -<div class="<?=$this->layoutClass('mainbody')?>"> - <?php /* finc V5: toggler was missing, remove entire template (!) when fixed in BS3 theme - CK */ ?> - <?=$this->render('RecordDriver/DefaultRecord/offcanvas-toggler-myresearch'); ?> +<a class="search-filter-toggle visible-xs" href="#myresearch-sidebar" data-toggle="offcanvas" title="Expand Sidebar"> + <?=$this->transEsc('Your Account') ?> +</a> + +<div class="<?=$this->layoutClass('mainbody')?>"> <h1><?=$this->transEsc('Interlibrary Loan Requests') ?></h1> <?=$this->flashmessages()?> @@ -176,7 +178,7 @@ <?php endif; ?> </div> -<div class="<?=$this->layoutClass('sidebar')?>"> +<div class="<?=$this->layoutClass('sidebar')?>" id="myresearch-sidebar"> <?=$this->context($this)->renderInContext("myresearch/menu.phtml", ['active' => 'ILLRequests'])?> </div> <!-- finc: myresearch - illrequests - END --> diff --git a/themes/finc/templates/myresearch/menu.phtml b/themes/finc/templates/myresearch/menu.phtml index 164a8be910bc5aab6916cf76afa8810bf9be8c4d..ba5ca11b9db37de21f7586a64399db952ef139b6 100644 --- a/themes/finc/templates/myresearch/menu.phtml +++ b/themes/finc/templates/myresearch/menu.phtml @@ -4,7 +4,6 @@ $user = $this->auth()->isLoggedIn(); $patron = $user ? $this->auth()->getILSPatron() : false; $capabilityParams = $patron ? ['patron' => $patron] : []; ?> -<?php /* Offcanvas closing button missing in BS3! CK*/ ?> <button class="close-offcanvas btn btn-default" data-toggle="offcanvas"><?=$this->transEsc('navigate_back') ?></button> <h2><?=$this->transEsc('Your Account')?></h2> @@ -41,8 +40,8 @@ $capabilityParams = $patron ? ['patron' => $patron] : []; <span id="getMyHolds" class="itemCount pull-right no-padding"></span> </a> <?php endif; ?> + <?php if ($this->ils()->checkFunction('StorageRetrievalRequests', $capabilityParams)): ?> - <a href="<?=$this->url('myresearch-storageretrievalrequests')?>" class="flex<?=$this->active == 'storageRetrievalRequests' ? ' active' : ''?>"> <span class="flex-col"><i class="fa fa-fw fa-archive" aria-hidden="true"></i> <?=$this->transEsc('Storage Retrieval Requests')?></span> <span class="storageretrievalrequests-status status hidden"><i class="fa fa-spin fa-spinner" aria-hidden="true"></i></span> @@ -50,16 +49,16 @@ $capabilityParams = $patron ? ['patron' => $patron] : []; <span id="getMyStorageRetrievalRequests" class="itemCount pull-right no-padding"></span> </a> <?php endif; ?> + <?php if ($this->ils()->checkFunction('ILLRequests', $capabilityParams)): ?> - <a href="<?=$this->url('myresearch-illrequests')?>" class="flex<?=$this->active == 'ILLRequests' ? ' active' : ''?>"> <span class="flex-col"><i class="fa fa-fw fa-exchange" aria-hidden="true"></i> <?=$this->transEsc('Interlibrary Loan Requests')?></span> <span class="illrequests-status status hidden"><i class="fa fa-spin fa-spinner" aria-hidden="true"></i></span> <?php /* nxt line finc specific - CK */ ?> <span id="getMyILLRequests" class="itemCount pull-right no-padding"></span> </a> - <?php endif; ?> + <?php if ($this->ils()->checkCapability('getMyFines', $capabilityParams)): ?> <a href="<?=$this->url('myresearch-fines')?>" class="flex<?=$this->active == 'fines' ? ' active' : ''?>"> <span class="flex-col"><i class="fa fa-fw fa-usd" aria-hidden="true"></i> <?=$this->transEsc('Fines')?></span> diff --git a/themes/finc/templates/myresearch/mylist.phtml b/themes/finc/templates/myresearch/mylist.phtml index c7ab5ac2b19d9f464742d54d3298ea867c2ffe70..96137debf508625da4aa17a7d91e3aa85976e2a8 100644 --- a/themes/finc/templates/myresearch/mylist.phtml +++ b/themes/finc/templates/myresearch/mylist.phtml @@ -26,12 +26,10 @@ $account = $this->auth()->getManager(); $user = $this->auth()->isLoggedIn(); ?> -<?=$this->flashmessages()?> - +<a class="search-filter-toggle visible-xs" href="#myresearch-sidebar" data-toggle="offcanvas" title="Expand Sidebar"> + <?=$this->transEsc('Your Account') ?> +</a> <div class="<?=$this->layoutClass('mainbody')?>"> - <?php /* finc V5: toggler was missing, remove entire template (!) when fixed in BS3 theme - CK */ ?> - <?=$this->render('RecordDriver/DefaultRecord/offcanvas-toggler-myresearch'); ?> - <h1><?=$list ? $this->escapeHtml($list->title) : $this->transEsc("Your Favorites")?></h1> <nav class="search-header hidden-print"> <div class="search-stats"> @@ -83,7 +81,7 @@ $user = $this->auth()->isLoggedIn(); <?php endif; ?> </div> -<div class="<?=$this->layoutClass('sidebar')?>"> +<div class="<?=$this->layoutClass('sidebar')?>" id="myresearch-sidebar"> <?php /* nxt-line and related endif are finc-specific #12053, CK*/ ?> <?php if ($user): ?> <?=$this->context($this)->renderInContext("myresearch/menu.phtml", ['active' => isset($list) ? 'list' . $list['id'] : 'favorites'])?> diff --git a/themes/finc/templates/myresearch/newpassword.phtml b/themes/finc/templates/myresearch/newpassword.phtml index beb486bd73a1cd9d3c5b57fa3ff16919754cb8a9..d6c79c657a275ab8d60730f59c6ff693677fbeef 100644 --- a/themes/finc/templates/myresearch/newpassword.phtml +++ b/themes/finc/templates/myresearch/newpassword.phtml @@ -1,6 +1,4 @@ <!-- finc - templates - myresearch - newpassword --> -<?php /* copied from bootstrap3 - h2 becomes h1 - #17596 - HR */?> - <?php // Set up page title: $this->headTitle($this->translate('Create New Password')); @@ -36,7 +34,7 @@ <?php if ($this->auth()->isLoggedIn()): ?> </div> - <div class="<?=$this->layoutClass('sidebar')?>"> + <div class="<?=$this->layoutClass('sidebar')?>" id="myresearch-sidebar"> <?=$this->context($this)->renderInContext("myresearch/menu.phtml", ['active' => 'newpassword'])?> </div> <?php endif; ?> diff --git a/themes/finc/templates/myresearch/profile.phtml b/themes/finc/templates/myresearch/profile.phtml index 5e584f7e85abfda012fe5f3b3150cbdf45bb94a5..17be7a17faa1fe2e38c4ef5ecec0d36721fe74ee 100644 --- a/themes/finc/templates/myresearch/profile.phtml +++ b/themes/finc/templates/myresearch/profile.phtml @@ -10,13 +10,14 @@ $arrTemplate = '<tr><th>%%LABEL%%:</th><td> %%VALUE%%</td></tr>'; ?> -<div class="<?= $this->layoutClass('mainbody') ?>"> - <?php /* finc V5: toggler was missing, remove entire template (!) when fixed in BS3 theme - CK */ ?> - <?= $this->render('RecordDriver/DefaultRecord/offcanvas-toggler-myresearch'); ?> +<a class="search-filter-toggle visible-xs" href="#myresearch-sidebar" data-toggle="offcanvas" title="Expand Sidebar"> + <?=$this->transEsc('Your Account') ?> +</a> + +<div class="<?=$this->layoutClass('mainbody')?>"> + <h1><?=$this->transEsc('Your Profile')?></h1> + <?=$this->flashmessages();?> - <h1><?= $this->transEsc('Your Profile') ?></h1> - <?= $this->flashmessages(); ?> - <?php /* works well without inserting resp data titles - CK */ ?> <table class="table table-striped"> <?= $this->renderArray( @@ -94,7 +95,7 @@ <?php endif; ?> </div> -<div class="<?= $this->layoutClass('sidebar') ?>"> +<div class="<?=$this->layoutClass('sidebar')?>" id="myresearch-sidebar"> <?= $this->context($this)->renderInContext("myresearch/menu.phtml", ['active' => 'profile']) ?> </div> <!-- finc: myresearch - profile - END --> diff --git a/themes/finc/templates/myresearch/storageretrievalrequests.phtml b/themes/finc/templates/myresearch/storageretrievalrequests.phtml index 11588df49a62990842f180eb6ec70de3379e2c14..6e8920b2ae8a2299ec4942f8809c38fb9d69ee3a 100644 --- a/themes/finc/templates/myresearch/storageretrievalrequests.phtml +++ b/themes/finc/templates/myresearch/storageretrievalrequests.phtml @@ -7,10 +7,11 @@ $this->layout()->breadcrumbs = '<li><a href="' . $this->url('myresearch-home') . '">' . $this->transEsc('Your Account') . '</a></li> <li class="active">' . $this->transEsc('Storage Retrieval Requests') . '</li>'; ?> -<div class="<?=$this->layoutClass('mainbody')?>"> - <?php /* finc V5: toggler was missing, remove entire template (!) when fixed in BS3 theme - CK */ ?> - <?=$this->render('RecordDriver/DefaultRecord/offcanvas-toggler-myresearch'); ?> +<a class="search-filter-toggle visible-xs" href="#myresearch-sidebar" data-toggle="offcanvas" title="Expand Sidebar"> + <?=$this->transEsc('Your Account') ?> +</a> +<div class="<?=$this->layoutClass('mainbody')?>"> <h1><?=$this->transEsc('Storage Retrieval Requests') ?></h1> <?=$this->flashmessages()?> @@ -173,7 +174,7 @@ <?php endif; ?> </div> -<div class="<?=$this->layoutClass('sidebar')?>"> +<div class="<?=$this->layoutClass('sidebar')?>" id="myresearch-sidebar"> <?=$this->context($this)->renderInContext("myresearch/menu.phtml", ['active' => 'storageRetrievalRequests'])?> </div> <!-- finc: myresearch - storageretrievalrequests - END --> diff --git a/themes/finc/templates/record/addtag.phtml b/themes/finc/templates/record/addtag.phtml index 6871aa6bdf3fd3395b7c09a3fca85daa7573412b..6d1a3cc3bc5c93e78e7c3bacaf26858c7d11ef25 100644 --- a/themes/finc/templates/record/addtag.phtml +++ b/themes/finc/templates/record/addtag.phtml @@ -1,6 +1,4 @@ <!-- finc - templates - record - addtag --> -<?php /* copied from bootstrap3 - h2 becomes h1 - #17596 - HR */?> - <?php // Set page title. $this->headTitle($this->translate('Add Tag')); diff --git a/themes/finc/templates/record/prev-next.phtml b/themes/finc/templates/record/prev-next.phtml index 0ee502839a65fcfe10e75332543c1eee102f93f1..bac5680bb85fb69eca72d10571108d61b3e24d9e 100644 --- a/themes/finc/templates/record/prev-next.phtml +++ b/themes/finc/templates/record/prev-next.phtml @@ -22,8 +22,8 @@ <?php endif; ?> <li class="disabled left" aria-hidden="true" role="none"><a href="#"><i class="fa fa-angle-left"></i> <?=$this->transEsc('Prev')?></a></li> <?php endif; ?> - <?php /* finc-specific wrapping: li + hidden-xs for consistency - CK */ ?> + <li class="hidden-xs"> <?=$this->transEsc('of_num_results', [ '%%position%%' => $this->localizedNumber($this->scrollData['currentPosition']), '%%total%%' => $this->localizedNumber($this->scrollData['resultTotal']) diff --git a/themes/finc/templates/record/save.phtml b/themes/finc/templates/record/save.phtml index 537c2ecdf07484da3a6ed09877633c458b304538..54b754eecc8b47310ae66ca0ae27c39253cddbbb 100644 --- a/themes/finc/templates/record/save.phtml +++ b/themes/finc/templates/record/save.phtml @@ -1,6 +1,4 @@ <!-- finc - templates - record - save --> -<?php /* copied from bootstrap3 - h2 becomes h1 - #17596 - HR */?> - <?php // Set page title. $this->headTitle($this->translate('Save')); diff --git a/themes/finc/templates/record/view.phtml b/themes/finc/templates/record/view.phtml index dc87e36b4332929517e7967b8f9c7a550df69ebd..1f97d387fad4ff410d80c391850a4220a5bfe5a1 100644 --- a/themes/finc/templates/record/view.phtml +++ b/themes/finc/templates/record/view.phtml @@ -15,7 +15,7 @@ // Set up breadcrumbs: $this->layout()->breadcrumbs = '<li>' . $this->searchMemory()->getLastSearchLink($this->transEsc('Search'), '', '</li> ') . - '<li class="active">' . $this->recordLink()->getBreadcrumb($this->driver) . '</li> '; + '<li class="active" aria-current="page">' . $this->recordLink()->getBreadcrumb($this->driver) . '</li> '; $this->layout()->title = $this->driver->getShortTitle(); ?> @@ -32,7 +32,8 @@ <?php /* finc: remove related-sidebar count and "solo" class since we use a custom sidebar, keep print classes, CK */ ?> <?php $sidebarList = $this->related()->getList($this->driver); ?> - <div class="<?= $this->layoutClass('mainbody') ?> print-full-width"> + <?php /* finc: remove the count of related-items-sidebars since we have a custom sidebar ! CK */ ?> + <div class="<?=$this->layoutClass('mainbody')?>"> <input type="hidden" value="<?= $this->escapeHtmlAttr($this->driver->getUniqueId()) ?>" class="hiddenId"/> <input type="hidden" value="<?= $this->escapeHtmlAttr($this->driver->getSourceIdentifier()) ?>" class="hiddenSource"/> <?= $this->flashmessages() ?> @@ -83,7 +84,7 @@ </div> - <div class="<?= $this->layoutClass('sidebar') ?>"> + <div class="<?= $this->layoutClass('sidebar') ?>" id="myresearch-sidebar"> <?php /* finc-specific: add toolbar to sidebar - CK */ ?> <?= $this->record($this->driver)->getToolbar() ?> diff --git a/themes/finc/templates/search/advanced/layout.phtml b/themes/finc/templates/search/advanced/layout.phtml index 3e133f9d664b256ed67b61d27e2199c0fddbbbdd..a7f4c048d40273945e2db99d5b19e3d0817b3919 100644 --- a/themes/finc/templates/search/advanced/layout.phtml +++ b/themes/finc/templates/search/advanced/layout.phtml @@ -159,7 +159,7 @@ if (isset($searchDetails) && is_object($searchDetails)) { <?php endif; ?> </div> - <div class="<?=$this->layoutClass('sidebar')?>"> + <div class="<?=$this->layoutClass('sidebar')?>" id="myresearch-sidebar"> <?php if ($hasDefaultsApplied): ?> <input type="hidden" name="dfApplied" value="1" /> <?php endif ?> diff --git a/themes/finc/templates/search/history-table.phtml b/themes/finc/templates/search/history-table.phtml index 296017e4c560ff6d5a381c6999e689d0d693f779..57e38252ee5552e41c570bd68d39319af9a65105 100644 --- a/themes/finc/templates/search/history-table.phtml +++ b/themes/finc/templates/search/history-table.phtml @@ -16,10 +16,10 @@ <td data-title="<?= $this->transEsc('history_search') ?>:"> <?= $this->historylabel($info->getParams()->getSearchClassId()) ?> - <a href="<?= $this->url($info->getOptions()->getSearchAction()) . $info->getUrlQuery()->getParams() ?>"><?php - $desc = $info->getParams()->getDisplayQuery(); - echo empty($desc) ? $this->transEsc("history_empty_search") : $this->escapeHtml($desc); - ?></a> + <a href="<?= $this->url($info->getOptions()->getSearchAction()) . $info->getUrlQuery()->getParams() ?>"><?php $desc = $info->getParams()->getDisplayQuery(); + echo empty($desc) ? $this->transEsc("history_empty_search") : $this->escapeHtml($desc); + ?> + </a> </td> <td data-title="<?= $this->transEsc('history_limits') ?>:"> @@ -43,13 +43,9 @@ <td data-title="<?= $this->transEsc($this->showSaved ? "history_delete" : "history_save") ?>"> <?php if ($this->showSaved): ?> - <a href="<?= $this->url('myresearch-savesearch') ?>?delete=<?= urlencode($info->getSearchId()) ?>&mode=history"><i class="fa fa-remove" - aria-hidden="true"></i> <?= $this->transEsc('history_delete_link') ?> - </a> + <a href="<?= $this->url('myresearch-savesearch') ?>?delete=<?= urlencode($info->getSearchId()) ?>&mode=history"><i class="fa fa-remove" aria-hidden="true"></i> <?= $this->transEsc('history_delete_link') ?></a> <?php else: ?> - <a href="<?= $this->url('myresearch-savesearch') ?>?save=<?= urlencode($info->getSearchId()) ?>&mode=history"><i class="fa fa-save" - aria-hidden="true"></i> <?= $this->transEsc("history_save_link") ?> - </a> + <a href="<?= $this->url('myresearch-savesearch') ?>?save=<?= urlencode($info->getSearchId()) ?>&mode=history"><i class="fa fa-save" aria-hidden="true"></i> <?= $this->transEsc("history_save_link") ?></a> <?php endif; ?> </td> <?php endif; ?> diff --git a/themes/finc/templates/search/history.phtml b/themes/finc/templates/search/history.phtml index 29d7a3adc3cc85133d83de8cbae4fb7157a7d967..f66a1c5c7df4e8c7d313814c226c911174780e58 100644 --- a/themes/finc/templates/search/history.phtml +++ b/themes/finc/templates/search/history.phtml @@ -1,6 +1,4 @@ <!-- finc - templates - search - history --> -<?php /* h2 becomes h1 - #17596 - HR */?> - <?php // Set page title. $this->headTitle($this->translate('Search History')); @@ -12,15 +10,16 @@ $saveSupported = $this->accountCapabilities()->getSavedSearchSetting() === 'enabled'; ?> +<a class="search-filter-toggle visible-xs" href="#myresearch-sidebar" data-toggle="offcanvas" title="Expand Sidebar"> + <?=$this->transEsc('Your Account') ?> +</a> + <div class="<?=$this->layoutClass('mainbody')?>"> + <?=$this->flashmessages()?> <?php if ($saveSupported && !empty($this->saved)): ?> <h1 class="sr-only"><?=$this->transEsc('Search History')?></h1> <?php endif; ?> - <?php /* finc V5: toggler was missing, remove entire template (!) when fixed in BS3 theme - CK */ ?> - <?=$this->render('RecordDriver/DefaultRecord/offcanvas-toggler-myresearch'); ?> - - <?=$this->flashmessages()?> <?php if ($saveSupported && !empty($this->saved)): ?> <h2><?=$this->transEsc("history_saved_searches")?></h2> <?=$this->context()->renderInContext('search/history-table.phtml', ['showSaved' => true]);?> @@ -40,7 +39,7 @@ </div> <?php if ($saveSupported): ?> - <div class="<?=$this->layoutClass('sidebar')?>"> + <div class="<?=$this->layoutClass('sidebar')?>" id="myresearch-sidebar"> <?=$this->context($this)->renderInContext( "myresearch/menu.phtml", // Only activate search history in account menu if user is logged in. diff --git a/themes/finc/templates/search/home.phtml b/themes/finc/templates/search/home.phtml index 50b8751fe6f6a5b8f40b07a68235f96b0879eb06..4fc8d20045f806bc73c723704385410dd97f7cd5 100644 --- a/themes/finc/templates/search/home.phtml +++ b/themes/finc/templates/search/home.phtml @@ -1,29 +1,29 @@ <!-- finc: search - home --> <?php -// Set page title. -$this->headTitle($this->translate('Search Home')); - -// finc: disable top search box here if you want the old look, see also below -// $this->layout()->searchbox = false; - -// Set default value if necessary: -if (!isset($this->searchClassId)) { - $this->searchClassId = 'Solr'; -} - -$this->layout()->breadcrumbs = false; + // Set page title. + $this->headTitle($this->translate('Search Home')); + + // finc: disable top search box here if you want the old look, see also below + // $this->layout()->searchbox = false; + + // Set default value if necessary: + if (!isset($this->searchClassId)) { + $this->searchClassId = 'Solr'; + } + + $this->layout()->breadcrumbs = false; ?> <div class="searchHomeContent"> - <h1><?=$this->transEsc("LibraryName")?></h1> -<?php /* finc: Activate search box below if you want the old look -- otherwise we keep the consistent look with searchbox in header */ ?> - <?php /* + <h1><?= $this->translate("LibraryName") ?></h1> + <?php /* finc: Activate search box below if you want the old look -- otherwise we keep the consistent look with searchbox in header */ ?> + <?php /* <?=$this->context($this)->renderInContext("search/searchbox.phtml", ['ignoreHiddenFilterMemory' => true])?> <?=$this->inlineScript(\Zend\View\Helper\HeadScript::SCRIPT, '$("#searchForm_lookfor").focus();', 'SET'); ?> </div> */ ?> </div> -<?=implode('', array_map([$this, 'contentBlock'], $blocks ?? []))?> +<?= implode('', array_map([$this, 'contentBlock'], $blocks ?? [])) ?> <!-- finc: search - home - END --> diff --git a/themes/finc/templates/search/newitem.phtml b/themes/finc/templates/search/newitem.phtml index e1af6817675997d0de9576c21a490168a19fc729..90b2a2077bfc8393592372667e03c42bf49b7f02 100644 --- a/themes/finc/templates/search/newitem.phtml +++ b/themes/finc/templates/search/newitem.phtml @@ -1,6 +1,4 @@ <!-- finc - templates - search - newitem --> -<?php /* copied from bootstrap3 - h2 becomes h1 - #17596 - HR */?> - <?php // Set up page title: $this->headTitle($this->translate('New Item Search')); diff --git a/themes/finc/templates/search/results.phtml b/themes/finc/templates/search/results.phtml index 1175c8e358f62a9b48d3f998e21cba5bab8e72b1..01364b6b21221c25ce69c8efefc9c0a70b36e3a4 100644 --- a/themes/finc/templates/search/results.phtml +++ b/themes/finc/templates/search/results.phtml @@ -71,9 +71,9 @@ $this->headScript()->appendFile("check_save_statuses.js"); <?=$this->context()->renderInContext('search/controls/showing.phtml', ['lookfor' => $lookfor, 'recordTotal' => $recordTotal]) ?> </span> <span class="offcanvas-toggler"> - <button class="search-filter-toggle btn btn-primary visible-xs" href="#search-sidebar" data-toggle="offcanvas" title="<?=$this->transEsc('sidebar_expand') ?>"> + <a class="search-filter-toggle btn btn-primary visible-xs" href="#myresearch-sidebar" data-toggle="offcanvas" title="<?=$this->transEsc('sidebar_expand') ?>"> <?=$this->transEsc('Refine Results') ?> - </button> + </a> </span> <?php else: ?> <h2><?=$this->transEsc('nohit_heading')?></h2> @@ -148,7 +148,7 @@ $this->headScript()->appendFile("check_save_statuses.js"); <?php /* End Main Listing */ ?> <?php /* Narrow Search Options */ ?> -<div class="<?=$this->layoutClass('sidebar')?>" id="search-sidebar"> +<div class="<?=$this->layoutClass('sidebar')?>" id="myresearch-sidebar"> <?php foreach ($this->results->getRecommendations('side') as $index => $current): ?> <?=$this->recommend($current, 'side', $index)?> <?php endforeach; ?> diff --git a/themes/finc/templates/search/searchbox.phtml b/themes/finc/templates/search/searchbox.phtml index e578f0ea4c45c1e55ecccf3d89861255a341dd68..33b1f02eab462b2d11d361236fd4347a887886b2 100644 --- a/themes/finc/templates/search/searchbox.phtml +++ b/themes/finc/templates/search/searchbox.phtml @@ -56,8 +56,7 @@ $hiddenFilterParams = $this->searchTabs()->getCurrentHiddenFilterParams($this->s <li class="hidden-xs"> <select id="searchForm_type" class="searchForm_type form-control" name="type" data-native-menu="false" aria-label="<?=$this->transEsc("Search type")?>"> <?php foreach ($handlers as $handler): ?> - <option - value="<?=$this->escapeHtmlAttr($handler['value'])?>"<?=$handler['selected'] ? ' selected="selected"' : ''?>><?=$handler['indent'] ? '-- ' : ''?><?=$this->transEsc($handler['label'])?></option> + <option value="<?=$this->escapeHtmlAttr($handler['value'])?>"<?=$handler['selected'] ? ' selected="selected"' : ''?>><?=$handler['indent'] ? '-- ' : ''?><?=$this->transEsc($handler['label'])?></option> <?php endforeach; ?> </select> </li>