Generate offline message in the template

This commit is contained in:
Dmitriy Simushev 2014-09-18 08:32:16 +00:00
parent c397a953a1
commit 911487871d
2 changed files with 1 additions and 6 deletions

View File

@ -48,7 +48,6 @@ class HomeController extends AbstractController
{
$operator = $this->getOperator();
$is_online = is_operator_online($operator['operatorid']);
$users_url = $this->generateUrl('users', array('nomenu' => 1));
$page = array(
'version' => MIBEW_VERSION,
@ -62,10 +61,6 @@ class HomeController extends AbstractController
'featuresPage' => $this->generateUrl('settings_features'),
'isOnline' => $is_online,
'warnOffline' => true,
'goOnlineLink' => getlocal(
"You are Offline.<br/><a href=\"{0}\">Connect...</a>",
array($users_url)
),
'title' => getlocal('Home'),
'menuid' => 'main',
);

View File

@ -4,7 +4,7 @@
{{#unless isOnline}}
<li id="offwarn">
<img src="{{asset "@CurrentStyle/images/dash/warn.gif"}}" alt="" width="24" height="24"/>
<p>{{{goOnlineLink}}}</p>
<p>{{{l10n "You are Offline.<br/><a href=\"{0}\">Connect...</a>" (route "users" nomenu="1")}}}</p>
</li>
{{/unless}}
{{/if}}