<button id="user-add" class="btn green-meadow"> <?php echo Module::t('create'); ?> <i class="fa fa-plus"></i> </button> </div> </div> </div> </div> </div> <?php /** * @var $jtable \liuxy\themes\admin\widgets\GridTable */ $jtable = GridTable::begin(['header' => ['username' => Module::t('user.username'), 'name' => Module::t('user.name'), 'status' => Module::t('status'), '' => Module::t('operation')]]); ?> <?php foreach ($data['items'] as $item) { echo $jtable->line($item, ['id' => 'tr-user-' . $item['id'], 'class' => 'odd gradeX'], ['' => '<div class="hidden-sm hidden-xs action-buttons"> <a class="green" href="#" onclick="user.get(' . $item['id'] . ');"> <i class="ace-icon fa fa-pencil bigger-130"></i> </a> </div>']); } ?> <?php GridTable::end(); ?> </div> </div>
<?php use liuxy\admin\widgets\GridTable; use liuxy\admin\Module; /** * @var $jtable \liuxy\admin\widgets\GridTable */ $jtable = GridTable::begin(['header' => ['id' => '#', 'text' => Module::t('name')]]); foreach ($data as $perm) { $perm['id'] = substr($perm['id'], strlen('node_'), strlen($perm['id']) - strlen('node_')); echo $jtable->line($perm, ['pid' => $perm['id']], ['id' => ['href' => 'javascript:', 'onclick' => 'perm.get(this,\'node_' . $perm['id'] . '\')'], 'text' => ['href' => 'javascript:', 'onclick' => 'perm.get(this,\'node_' . $perm['id'] . '\')']]); } if ($item) { echo '<input type="hidden" id="goback" value="node_' . $item['parent_id'] . '"/>'; } GridTable::end();
<div class="btn-group"> <button id="role-add" class="btn green-meadow"> <?php echo Module::t('create'); ?> <i class="fa fa-plus"></i> </button> </div> </div> </div> </div> <?php /** * @var $jtable \liuxy\admin\widgets\GridTable */ $jtable = GridTable::begin(['header' => ['name' => Module::t('name'), 'description' => Module::t('description'), 'status' => Module::t('status'), '' => Module::t('operation')]]); ?> <?php foreach ($data['items'] as $item) { echo $jtable->line($item, ['id' => 'tr-role-' . $item['id'], 'class' => 'odd gradeX'], ['' => '<div class="hidden-sm hidden-xs action-buttons"> <a class="green" href="#" onclick="role.get(' . $item['id'] . ');"> <i class="ace-icon fa fa-pencil bigger-130"></i> </a> <a class="red" href="#" onclick="role.delete(' . $item['id'] . ');"> <i class="ace-icon fa fa-trash-o bigger-130"></i> </a> </div>']); } ?> <?php
<button id="user-add" class="btn green-meadow"> <?php echo Module::t('create'); ?> <i class="fa fa-plus"></i> </button> </div> </div> </div> </div> </div> <?php /** * @var $jtable \liuxy\admin\widgets\GridTable */ $jtable = GridTable::begin(['header' => ['username' => Module::t('user.username'), 'name' => Module::t('user.name'), 'status' => Module::t('status'), 'trd_identifier' => Module::t('user.third.identifier'), '' => Module::t('operation')]]); ?> <?php foreach ($data['items'] as $item) { echo $jtable->line($item, ['id' => 'tr-user-' . $item['id'], 'class' => 'odd gradeX'], ['' => '<div class="hidden-sm hidden-xs action-buttons"> <a class="green" href="#" onclick="user.get(' . $item['id'] . ');"> <i class="ace-icon fa fa-pencil bigger-130"></i> </a> </div>']); } ?> <?php GridTable::end(); ?> </div> </div>