Exemple #1
0
<?php

use app\widgets\Nav;
use yii\bootstrap\NavBar;
NavBar::begin(['id' => 'site_header', 'options' => ['class' => 'header navbar-default navbar-static-top']]);
Nav::begin(['items' => [['label' => Yii::t('app', 'Wish List'), 'url' => ['/checkout/wish-list/index']], ['label' => Yii::t('app', 'Shopping cart'), 'url' => ['/checkout/cart/index']], ['label' => Yii::t('app', 'Checkout'), 'url' => ['/checkout/order/address']]], 'options' => ['class' => 'navbar-nav']]);
Nav::end();
?>

<?php 
echo $this->render('//shared/mini_cart');
echo $this->render('//shared/currencies');
?>

<?php 
Nav::begin(['encodeLabels' => false, 'items' => Yii::$app->user->isGuest ? [['label' => Yii::t('app', 'Sign in'), 'url' => ['/user/account/login']], ['label' => Yii::t('app', 'Sign up'), 'url' => ['/user/account/register']]] : [['label' => Yii::t('app', 'My account'), 'url' => ['/user/account/details'], 'scope' => ['account']], ['label' => Yii::t('app', 'Sign out ({0})', Yii::$app->user->identity->name), 'url' => ['/user/account/logout'], 'linkOptions' => ['data-method' => 'post']]], 'options' => ['class' => 'login-links navbar-nav pull-right']]);
Nav::end();
NavBar::end();
Exemple #2
0
echo Html::encode($this->title);
?>
</title>
    <?php 
$this->head();
?>
</head>
<body>
<?php 
$this->beginBody();
?>
<body>
  <header class="navbar navbar-static-top bs-docs-nav" id="top" role="banner">
  <div class="container">
    <?php 
echo Nav::widget();
?>
  </div>
  </header>
  <?php 
echo $content;
?>
  <footer class="bs-docs-footer" role="contentinfo">
    <div class="container">
    <p>鄂ICP备16001924号-1 &copy;2016 宜昌交通旅游集团</p>
    <p><?php 
echo Links::widget();
?>
</p>
      <ul class="bs-docs-footer-links text-muted">
        <li><a href="http://www.ycjyjt.com/" target="_blank">宜昌交运集团</a></li>
Exemple #3
0
<?php

use app\widgets\Nav;
use yii\bootstrap\NavBar;
NavBar::begin(['brandLabel' => '用户中心', 'brandUrl' => ['/account/index'], 'options' => ['class' => 'navbar-inverse navbar-fixed-top', 'style' => 'background-color:#fff;border-color:#fff;']]);
echo Nav::widget(['options' => ['class' => 'navbar-nav'], 'items' => [['label' => '修改密码', 'url' => ['/account/change-password']], ['label' => '更改头像', 'url' => ['/account/change-portrait']], ['label' => '我的评论', 'url' => ['/account/my-comment']]]]);
if (!Yii::$app->user->identity->isAdmin) {
    $items = [['label' => '[ ' . Yii::$app->user->identity->email . '] ', 'items' => [['label' => '回到博客', 'url' => ['/site/index']], '<li class="divider"></li>', ['label' => '退出', 'url' => ['/auth/logout'], 'linkOptions' => ['data-method' => 'post']]]]];
} elseif (Yii::$app->user->identity->isAdmin) {
    $items = [['label' => '[ ' . Yii::$app->user->identity->email . '] ', 'items' => [['label' => '进入后台', 'url' => ['/admin/default/index']], ['label' => '回到博客', 'url' => ['/site/index']], '<li class="divider"></li>', ['label' => '退出', 'url' => ['/auth/logout'], 'linkOptions' => ['data-method' => 'post']]]]];
}
echo Nav::widget(['options' => ['class' => 'navbar-nav navbar-right'], 'items' => $items]);
NavBar::end();
Exemple #4
0
<div class="navbar navbar-inverse mybar navbar-static-top">
    <a class="heading" href="/"><?php 
echo Html::img('@web/img/logo.png');
?>
</a>
    <span class="inline-block logo-text" ><a style="color: #fff" href="/">Бурятский республиканский<br>институт образовательной политики</a></span>
    <?php 
echo UserControl::widget(['user' => Yii::$app->user]);
?>
</div>

<div class="container-fluid">
    <div class="row">
        <div class="col-md-2">
            <?php 
echo Nav::widget(['options' => ['class' => 'nav-pills nav-stacked']]);
?>
        </div>
        <div class="col-md-10">
            <?php 
echo $content;
?>
        </div>
    </div>
</div>

<footer class="footer myfooter">&copy; <?php 
echo date('Y');
?>
 БРИОП</footer>
<?php 
Exemple #5
0
use app\modules\admin\models\AddProductForm;
use app\modules\checkout\models\Order;
use app\widgets\BackLink;
use app\widgets\Nav;
use yii\bootstrap\ActiveForm;
use yii\bootstrap\Html;
use yii\data\ArrayDataProvider;
use yii\grid\GridView;
use yii\helpers\Url;
/**
 * @var Order $order
 * @var AddProductForm $newProduct
 */
$this->title = Yii::t('app', 'Order items');
$items = $order->orderLines;
echo Nav::widget(['encodeLabels' => false, 'items' => [['label' => BackLink::widget(['title' => Yii::t('app', 'Order'), 'textOnly' => true]), 'url' => Url::to(['/admin/order/update', 'id' => $order->id]), 'active' => true]], 'options' => ['class' => 'nav-pills']]);
?>

<h3><?php 
echo Yii::t('app', 'Info');
?>
</h3>
<table class="table table-bordered table-striped">
    <tr>
        <th><?php 
echo Yii::t('app', 'ID');
?>
</th>
        <td><?php 
echo $order->id;
?>