Authored by wuxiao

商品管理

<?php
namespace backend\controllers;
use Yii;
/**
* Live controller
*/
class ProductController extends BaseController
{
/**
* 房间商品列表
* @return type
*/
public function actionList()
{
if (!$room_id = Yii::$app->getRequest()->getQueryParam('id')){
return $this->redirect($this->_refer);
}
return $this->render('list');
}
}
... ...
... ... @@ -61,6 +61,8 @@ $this->title = $this->params['main_title'].'-'.$this->params['sub_title'];
<a href="/live/roomedit/<?=$model->id?>" class="btn btn-default btn-white">编辑</a>
<a href="/forbidden/index?room_id=<?=$model->room_id?>" class="btn btn-default btn-white">禁言</a>
<a href="/product/list/<?=$model->room_id?>" class="btn btn-default btn-white">商品</a>
<span>
<?php if ($model->status == 0)://未开始?>
... ...
<?php
use yii\helpers\Html;
use backend\widgets\LinkPager;
$this->title = $this->params['main_title'].'-'.$this->params['sub_title'];
?>
<div class="form-group">
<label>
<a href="/live/roomcreate" class="btn btn-primary">+ 创建房间</a>
</label>
</div>
<div class="row">
<div class="col-md-12">
<div class="table-responsive">
<table class="table mb30">
<thead>
<tr style="white-space:nowrap">
<th><input type="checkbox" onclick="checkall(this)">选择</th>
<th>房间号</th>
<th>APP</th>
<th>直播标题</th>
<th>头图</th>
<th>主播</th>
<th>预告开始时间</th>
<th>房间密钥</th>
<th>是否精选</th>
<th>马甲状态</th>
<th>直播状态</th>
<th>操作</th>
</tr>
</thead>
<tbody>
</tbody>
</table>
</div>
<!-- table-responsive -->
</div>
<!-- col-md-12 -->
</div>
\ No newline at end of file
... ...