当前位置: 首页>>代码示例>>PHP>>正文


PHP Menu::getAdminMenu方法代码示例

本文整理汇总了PHP中Menu::getAdminMenu方法的典型用法代码示例。如果您正苦于以下问题:PHP Menu::getAdminMenu方法的具体用法?PHP Menu::getAdminMenu怎么用?PHP Menu::getAdminMenu使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Menu的用法示例。


在下文中一共展示了Menu::getAdminMenu方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: run

 public function run()
 {
     $aMenu = \Menu::getAdminMenu();
     $tMenu = \Menu::getTeacherMenu();
     $sMenu = \Menu::getStudentMenu();
     $i = 0;
     (new \MenuItem($aMenu->id, '/admin', 'Home', 0, $i++))->save();
     (new \MenuItem($aMenu->id, '/addarticle', 'Add Article', 0, $i++))->save();
     (new \MenuItem($aMenu->id, '/articlemanager', 'Article Manager', 0, $i++))->save();
     (new \MenuItem($aMenu->id, '/usermanager', 'User Manager', 0, $i++))->save();
     (new \MenuItem($aMenu->id, '/addchallenge', 'Add Challenge', 0, $i++))->save();
     (new \MenuItem($aMenu->id, '/challengemanager', 'Challenge Manager', 0, $i++))->save();
     (new \MenuItem($aMenu->id, '/menumanager', 'Menu Manager', 0, $i++))->save();
     (new \MenuItem($aMenu->id, '/options', 'Options', 0, $i++))->save();
     (new \MenuItem($aMenu->id, '/logout', 'Logout', 0, $i++))->save();
     $i = 0;
     (new \MenuItem($tMenu->id, '/admin', 'Home', 0, $i++))->save();
     (new \MenuItem($tMenu->id, '/addarticle', 'Add Article', 0, $i++))->save();
     (new \MenuItem($aMenu->id, '/articlemanager', 'Article Manager', 0, $i++))->save();
     (new \MenuItem($tMenu->id, '/usermanager', 'User Manager', 0, $i++))->save();
     (new \MenuItem($tMenu->id, '/addchallenge', 'Add Challenge', 0, $i++))->save();
     (new \MenuItem($tMenu->id, '/challengemanager', 'Challenge Manager', 0, $i++))->save();
     (new \MenuItem($tMenu->id, '/menumanager', 'Menu Manager', 0, $i++))->save();
     (new \MenuItem($tMenu->id, '/options', 'Options', 0, $i++))->save();
     $i = 0;
     (new \MenuItem($sMenu->id, '/home', 'Home', 0, $i++))->save();
     (new \MenuItem($sMenu->id, '/progress', 'Progress Report', 0, $i++))->save();
     (new \MenuItem($sMenu->id, '/ranking', 'Ranking', 0, $i++))->save();
     (new \MenuItem($sMenu->id, '/ranking', 'Ranking', 0, $i++))->save();
     (new \MenuItem($sMenu->id, '/challenges', 'Challenges', 0, $i++))->save();
     (new \MenuItem($sMenu->id, '/logout', 'Logout', 0, $i++))->save();
 }
开发者ID:northdpole,项目名称:laravelTest,代码行数:32,代码来源:MenuItemSeeder.php

示例2: array

        <!-- BEGIN CONTAINER -->
        <div id="container" class="row-fluid">
            <!-- BEGIN SIDEBAR -->
            <div class="sidebar-scroll">

                <div id="sidebar" class="nav-collapse collapse">
                    <!-- BEGIN RESPONSIVE QUICK SEARCH FORM -->
                    <div class="navbar-inverse">
                        <form class="navbar-search visible-phone">
                            <input type="text" class="search-query" placeholder="Search" />
                        </form>
                    </div>
                    <!-- END RESPONSIVE QUICK SEARCH FORM -->
                    <!-- BEGIN SIDEBAR MENU -->
                    <?php 
$this->widget('zii.widgets.CMenu', array('items' => $this->admin ? Menu::getAdminMenu($this) : Menu::getMenu($this), 'encodeLabel' => false, 'itemCssClass' => 'sub-menu', 'activeCssClass' => 'active', 'htmlOptions' => array('class' => 'sidebar-menu'), 'submenuHtmlOptions' => array('class' => 'sub')));
?>
                    <!-- END SIDEBAR MENU -->
                </div>
            </div>
            <!-- END SIDEBAR -->

            <!-- BEGIN PAGE -->  
            <div id="main-content">
                <!-- BEGIN PAGE CONTAINER-->
                <div class="container-fluid">
                    <!-- BEGIN PAGE HEADER-->
                    <!-- FLASH MESSAGES -->
                    <div class="row-fluid">
                        <div id="maiMessages" class="flash-messages">
                            <?php 
开发者ID:richardm6,项目名称:bdd3-project,代码行数:31,代码来源:main.php

示例3: array

                        </span>
                        <i class="fa fa-angle-down"></i>
                    </a> 

                </span>
            </div>
            <!-- end user info -->

            <!-- NAVIGATION : This navigation is also responsive

            -->
            <nav>


                <?php 
$this->widget('zii.widgets.CMenu', array('id' => 'menu_principal', 'items' => $this->admin ? Menu::getAdminMenu($this) : Menu::getMenu($this), 'encodeLabel' => false));
?>

            </nav>
            <span class="minifyme"> <i class="fa fa-arrow-circle-left hit"></i> </span>

        </aside>
        <!-- END NAVIGATION -->

        <!-- MAIN PANEL -->
        <div id="main" role="main">

            <!-- RIBBON -->
            <div id="ribbon">
                <span class="ribbon-button-alignment"> <span id="refresh" class="btn btn-ribbon" data-title="refresh"  rel="tooltip" data-placement="bottom" data-original-title="<i class='text-warning fa fa-warning'></i> Warning! This will reset all your widget settings." data-html="true"><i class="fa fa-refresh"></i></span> </span>
                <!-- breadcrumb -->
开发者ID:migu3ln,项目名称:node-curso-ejemplos,代码行数:31,代码来源:main.php

示例4: nav

        <section class="section-content">
            <!-- side left, its part to menu on left-->
            <div id="navside" class="side-left side-left-fixed  hidden-phone " data-collapse="navbar" style="min-height: 100%;">
                <!--@form search-->
                <!--                <form class="form-inline search-module" action="?" method="post" >
                                    <div class="input-append input-append-inline">
                                        <input name="search" class="input-block-level" type="text" placeholder="Type to search" />
                                        <button class="btn bg-cyan" type="button">
                                            <i class="aweso-search"></i>
                                        </button>
                                    </div>
                                </form>-->
                <!--nav, this structure create with nav (find the bootstrap doc about .nav list) -->

                <?php 
$this->widget('zii.widgets.CMenu', array('items' => $this->admin ? Menu::getAdminMenu($this) : Menu::getMenu($this), 'encodeLabel' => false, 'activeCssClass' => 'active', 'htmlOptions' => array('class' => 'nav nav-list'), 'submenuHtmlOptions' => array('class' => 'dropdown-menu')));
?>

                <!--/ nav -->
            </div><!--/ side left-->



            <!-- start content -->
            <div class="content">
                <!-- FLASH MESSAGES -->

                <div class="row-fluid" id="maiMessages" class="flash-messages">                    
                    <!--<div id="maiMessages" >-->
                    <?php 
$messages = Yii::app()->user->getFlashes();
开发者ID:Wladimir89,项目名称:software1grh,代码行数:31,代码来源:main.php


注:本文中的Menu::getAdminMenu方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。