本文整理汇总了PHP中Admin\Builder\AdminListBuilder::clearTrash方法的典型用法代码示例。如果您正苦于以下问题:PHP AdminListBuilder::clearTrash方法的具体用法?PHP AdminListBuilder::clearTrash怎么用?PHP AdminListBuilder::clearTrash使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Admin\Builder\AdminListBuilder
的用法示例。
在下文中一共展示了AdminListBuilder::clearTrash方法的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: commentTrash
public function commentTrash($page = 1, $r = 20, $model = '')
{
$builder = new AdminListBuilder();
$builder->clearTrash($model);
//读取评论列表
$map = array('status' => -1);
$model = M('WeiboComment');
$list = $model->where($map)->order('create_time asc')->page($page, $r)->select();
$totalCount = $model->where($map)->count();
//显示页面
$builder->title('回复回收站')->setStatusUrl(U('setCommentStatus'))->buttonRestore()->buttonClear('WeiboComment')->keyId()->keyText('content', '内容')->keyUid()->keyCreateTime()->data($list)->pagination($totalCount, $r)->display();
}
示例2: contentTrash
public function contentTrash($page = 1, $r = 10, $model = '')
{
//读取微博列表
$builder = new AdminListBuilder();
//内含 delete 方法
$builder->clearTrash($model);
$map = array('status' => -1);
$model = D('IssueContent');
$list = $model->where($map)->page($page, $r)->select();
$totalCount = $model->where($map)->count();
//显示页面
$builder->title('内容回收站')->setStatusUrl(U('setIssueContentStatus'))->buttonRestore()->buttonClear('IssueContent')->keyId()->keyLink('title', '标题', 'Issue/Index/issueContentDetail?id=###')->keyUid()->keyCreateTime()->keyStatus()->data($list)->pagination($totalCount, $r)->display();
}
示例3: commentTrash
public function commentTrash()
{
$aPage = I('page', 1, 'intval');
$r = 20;
$builder = new AdminListBuilder();
$builder->clearTrash('WeiboComment');
//读取评论列表
$map = array('status' => -1);
$model = M('WeiboComment');
$list = $model->where($map)->order('id desc')->page($aPage, $r)->select();
$totalCount = $model->where($map)->count();
//显示页面
$builder->title(L('_REPLY_TRASH_'))->setStatusUrl(U('setCommentStatus'))->buttonRestore()->buttonClear('WeiboComment')->keyId()->keyText('content', L('_CONTENT_'))->keyUid()->keyCreateTime()->data($list)->pagination($totalCount, $r)->display();
}
示例4: replyTrash
public function replyTrash($page = 1, $r = 20, $model = '')
{
$builder = new AdminListBuilder();
$builder->clearTrash($model);
//读取回复列表
$map = array('status' => -1);
$model = M('ForumPostReply');
$list = $model->where($map)->order('create_time asc')->page($page, $r)->select();
foreach ($list as &$reply) {
$reply['content'] = op_t($reply['content']);
}
unset($reply);
$totalCount = $model->where($map)->count();
//显示页面
$builder->title('回复回收站')->setStatusUrl(U('setReplyStatus'))->buttonRestore()->buttonClear('ForumPostReply')->keyId()->keyTruncText('content', '内容', 50)->keyCreateTime()->keyUpdateTime()->keyStatus()->data($list)->pagination($totalCount, $r)->display();
}
示例5: entityTrash
public function entityTrash($page = 1, $r = 20)
{
$aModel = I('model', 'CatEntity', 'text');
$listBuilder = new AdminListBuilder();
$listBuilder->clearTrash($aModel);
$data = M('cat_entity')->where('status=-1')->page($page, $r)->order('sort desc')->select();
$totalCount = M('cat_entity')->where('status=-1')->count();
foreach ($data as &$v) {
$v['fields'] = '字段管理';
}
unset($v);
$listBuilder->title('模型回收站')->keyId()->keyLink('name', '模型英文名', 'info?entity_id=###')->keyLink('alias', '模型中文名', 'info?entity_id=###')->keyLink('fields', '字段管理', 'field?entity_id=###')->keyStatus()->keyText('sort', '排序')->keyDoActionEdit('editEntity?entity_id=###')->data($data)->pagination($totalCount, $r);
$listBuilder->buttonRestore(U('dodelentity'))->buttonClear('CatEntity');
$listBuilder->display();
}
示例6: eventTypeTrash
public function eventTypeTrash($page = 1, $r = 20)
{
$builder = new AdminListBuilder();
$builder->clearTrash('EventType');
//读取微博列表
$map = array('status' => -1);
$model = $this->eventTypeModel;
$list = $model->where($map)->page($page, $r)->select();
$totalCount = $model->where($map)->count();
//显示页面
$builder->title('活动类型回收站')->setStatusUrl(U('setStatus'))->buttonRestore()->buttonClear()->keyId()->keyText('title', '标题')->keyStatus()->keyCreateTime()->data($list)->pagination($totalCount, $r)->display();
}
示例7: goodsTrash
public function goodsTrash($page = 1, $r = 10, $model = '')
{
$builder = new AdminListBuilder();
$builder->clearTrash($model);
//读取微博列表
$map = array('status' => -1);
$goodsList = $this->shopModel->where($map)->order('changetime desc')->page($page, $r)->select();
$totalCount = $this->shopModel->where($map)->count();
//显示页面
$builder->title('商品回收站')->setStatusUrl(U('setGoodsStatus'))->buttonRestore()->buttonClear('Shop/Shop')->keyId()->keyLink('goods_name', '标题', 'Shop/goodsEdit?id=###')->keyCreateTime()->keyStatus()->data($goodsList)->pagination($totalCount, $r)->display();
}