diff --git a/module/finc/src/finc/Controller/AjaxController.php b/module/finc/src/finc/Controller/AjaxController.php index f0e7bdbc6d20b50c49036381092a925bb7e94361..d3f3b3b9edf47d609d07dbb1ef533a81598527cd 100644 --- a/module/finc/src/finc/Controller/AjaxController.php +++ b/module/finc/src/finc/Controller/AjaxController.php @@ -283,9 +283,16 @@ class AjaxController extends \VuFind\Controller\AjaxController protected function getIlsStatusAjax() { $this->disableSessionWrites(); // avoid session write timing bug + $offlineModeMsg = $this->params()->fromPost( + 'offlineModeMsg', + $this->params()->fromQuery('offlineModeMsg') + ); if ($this->getILS()->getOfflineMode() == 'ils-offline') { return $this->output( - $this->getViewRenderer()->render('Helpers/ils-offline.phtml'), + $this->getViewRenderer()->render( + 'Helpers/ils-offline.phtml', + ['offlineModeMsg' => $offlineModeMsg] + ), self::STATUS_OK ); } diff --git a/themes/finc/templates/Helpers/ils-offline.phtml b/themes/finc/templates/Helpers/ils-offline.phtml index a0c357398679c1cdad5c149cdef56edf45a7dfae..b99244a06af91be485236a7254fcd6fdeeba30ed 100644 --- a/themes/finc/templates/Helpers/ils-offline.phtml +++ b/themes/finc/templates/Helpers/ils-offline.phtml @@ -1,7 +1,7 @@ <div data-alert class="alert-box warning" tabindex="0" aria-live="assertive" role="dialogalert"> <h2><?=$this->transEsc('ils_offline_title')?></h2> <p><strong><?=$this->transEsc('ils_offline_status')?></strong></p> - <p><?=$this->transEsc('ils_offline_home_message')?></p> + <p><?=$this->transEsc($this->offlineModeMsg)?></p> <? $supportEmail = $this->escapeHtmlAttr($this->systemEmail()); ?> <p><a href="mailto:<?=$supportEmail?>"><?=$supportEmail?></a></p> </div> \ No newline at end of file diff --git a/themes/finc/templates/RecordTab/holdingsils.phtml b/themes/finc/templates/RecordTab/holdingsils.phtml index c7e92db0c1a8e9844d7a275d33b833afe2cc2939..cdf8d70db3628089d9e106d1e0da1101925794dc 100644 --- a/themes/finc/templates/RecordTab/holdingsils.phtml +++ b/themes/finc/templates/RecordTab/holdingsils.phtml @@ -26,7 +26,7 @@ <?=$this->context($this)->renderInContext('librarycards/selectcard.phtml', array('user' => $this->auth()->isLoggedIn())); ?> -<?=($offlineMode == "ils-offline") ? $this->render('Helpers/ils-offline.phtml') : ''?> +<?=($offlineMode == "ils-offline") ? $this->render('Helpers/ils-offline.phtml', ['offlineModeMsg' => 'ils_offline_holdings_message']) : ''?> <? if (($this->ils()->getHoldsMode() == 'driver' && !empty($holdings)) || $this->ils()->getTitleHoldsMode() == 'driver'): ?> <? if ($account->loginEnabled() && $offlineMode != 'ils-offline'): ?> <? if (!$user): ?> diff --git a/themes/finc/templates/myresearch/cataloglogin.phtml b/themes/finc/templates/myresearch/cataloglogin.phtml index 2c4cdeeecbb44e275bb3cb5ae52c738a04cc2cf7..954777353884c1a2c48349d4c3f4d12e0fd8e63a 100644 --- a/themes/finc/templates/myresearch/cataloglogin.phtml +++ b/themes/finc/templates/myresearch/cataloglogin.phtml @@ -10,7 +10,7 @@ $offlineMode = $this->ils()->getOfflineMode(); ?> <? if ($offlineMode == "ils-offline"): ?> - <?=$this->render('Helpers/ils-offline.phtml')?> + <?=$this->render('Helpers/ils-offline.phtml', ['offlineModeMsg' => 'ils_offline_login_message'])?> <? else: ?> <h3><?=$this->transEsc('Library Catalog Profile')?></h3> <?=$this->flashmessages()?> diff --git a/themes/finc/templates/myresearch/login.phtml b/themes/finc/templates/myresearch/login.phtml index 9f042be87e320a473444ac56655f95cb2ca34dc9..ad394da1d3532adcb521fac4b1261d40abb43c0a 100644 --- a/themes/finc/templates/myresearch/login.phtml +++ b/themes/finc/templates/myresearch/login.phtml @@ -12,7 +12,7 @@ ?> <? if ($offlineMode == "ils-offline"): ?> - <?=$this->render('Helpers/ils-offline.phtml')?> + <?=$this->render('Helpers/ils-offline.phtml', ['offlineModeMsg' => 'ils_offline_login_message'])?> <? else: ?> <h2><?=$this->transEsc('Login')?></h2> <?=$this->flashmessages()?> diff --git a/themes/finc/templates/search/home.phtml b/themes/finc/templates/search/home.phtml index 9907e573ada89216da2ca48ab21594dbbb7b72fb..9f0cf95d8ec62043f287df1a01d10713648d1421 100644 --- a/themes/finc/templates/search/home.phtml +++ b/themes/finc/templates/search/home.phtml @@ -26,6 +26,7 @@ $this->layout()->breadcrumbs = false; $.ajax({ dataType: 'json', method: 'GET', + data: {'offlineModeMsg':'ils_offline_home_message'}, url: VuFind.path + '/AJAX/JSON?method=getIlsStatus', success: function(response) { $('.searchHomeContent').append(response.data);