PATH:
home
/
letacommog
/
letaweb
/
protected
/
modules
/
admin
/
views
/
user
<div class="body"> <div class="row"> <div class="col-md-12"> <div class="panel panel-default"> <div class="panel-title"> <h5>User list</h5> </div> <div class="panel-body"> <div class="btn-group"> <?php echo CHtml::link('Add', array('user/create'), array('class' => 'btn font-plus')); ?> </div> <?php $columns = array( array( 'id' => 'autoId', 'class' => 'CCheckBoxColumn', 'selectableRows' => '50', ), array( 'header' => CHtml::encode('ID'), 'name' => 'id', 'headerHtmlOptions' => array('style' => 'width:100px'), ), array( 'header' => CHtml::encode('Name'), 'name' => 'name', ), array( 'header' => CHtml::encode('Email'), 'name' => 'email', ), array( 'class' => 'booster.widgets.TbToggleColumn', 'toggleAction' => ('user/setAdmin'), 'name' => 'is_admin', 'header' => CHtml::encode('Is Admin'), 'filter' => array('1' => 'Yes','0' => 'No'), ), array( 'class' => 'booster.widgets.TbToggleColumn', 'toggleAction' => $this->createUrl('user/active'), 'name' => 'is_active', 'header' => CHtml::encode('Active'), 'filter' => array('1' => 'Yes','0' => 'No'), ), array( 'class' => 'CGridButtonColumn', 'template' => '{update}', ), ); $form = $this->beginWidget('CActiveForm', array( 'enableAjaxValidation' => true, )); $this->widget('booster.widgets.TbGridView', array( 'id' => 'user-grid', 'type' => 'striped bordered', 'dataProvider' => $model->search_admin(), 'columns' => $columns, 'filter' => $model, )); ?> <div class="btn-group"> <?php echo CGridControls::ajaxActiveUsersButton('Active', array('user/ajaxupdate', 'act' => 'doActive'), array('success' => 'reloadGrid'), array('class' => 'btn btn-info')); ?> <?php echo CGridControls::ajaxInActiveUsersButton('Deactive', array('user/ajaxupdate', 'act' => 'doInactive'), array('success' => 'reloadGrid'), array('class' => 'btn btn-danger')); ?> </div> <?php $this->endWidget(); ?> </div> </div> </div> </div> </div> <script> function reloadGrid(data) { $.fn.yiiGridView.update('user-grid'); } </script>
[+]
..
[-] update.php
[edit]
[-] create_form.php
[edit]
[-] create.php
[edit]
[-] reset.php
[edit]
[-] index.php
[edit]
[-] update_form.php
[edit]