删除后台行为功能模块
增加微信公众号功能模块
This commit is contained in:
@@ -144,7 +144,7 @@ class Menu extends Admin {
|
|||||||
$map[] = ['id', '=', $id];
|
$map[] = ['id', '=', $id];
|
||||||
}
|
}
|
||||||
|
|
||||||
$result = MenuM::where($map)->delete()
|
$result = MenuM::where($map)->delete();
|
||||||
if (false !== $result) {
|
if (false !== $result) {
|
||||||
Cache::pull('admin_menu_list');
|
Cache::pull('admin_menu_list');
|
||||||
return $this->success('删除成功');
|
return $this->success('删除成功');
|
||||||
|
|||||||
@@ -8,35 +8,33 @@
|
|||||||
// +----------------------------------------------------------------------
|
// +----------------------------------------------------------------------
|
||||||
|
|
||||||
namespace app\controller\admin;
|
namespace app\controller\admin;
|
||||||
|
|
||||||
use app\controller\Admin;
|
use app\controller\Admin;
|
||||||
|
use app\model\Wechat as WechatM;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @title 行为管理
|
* @title 微信公众号
|
||||||
* @description 行为管理
|
* @description 微信公众号管理
|
||||||
*/
|
*/
|
||||||
class Action extends Admin {
|
class Wechat extends Admin {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @title 用户行为列表
|
* @title 公众号列表
|
||||||
* @author huajie <banhuajie@163.com>
|
* @author huajie <banhuajie@163.com>
|
||||||
*/
|
*/
|
||||||
public function index() {
|
public function index() {
|
||||||
$map = array('status' => array('gt', -1));
|
// $map = array('status' => array('gt', -1));
|
||||||
|
|
||||||
$order = "id desc";
|
// $order = "id desc";
|
||||||
//获取列表数据
|
// //获取列表数据
|
||||||
$list = model('Action')->where($map)->order($order)->paginate(10, false, array(
|
// $list = WechatM::where($map)->order($order)->paginate(10, false, array(
|
||||||
'query' => $this->request->param(),
|
// 'query' => $this->request->param(),
|
||||||
));
|
// ));
|
||||||
|
|
||||||
// 记录当前列表页的cookie
|
$this->data = array(
|
||||||
Cookie('__forward__', $_SERVER['REQUEST_URI']);
|
'list' => [],
|
||||||
$data = array(
|
'page' => '',
|
||||||
'list' => $list,
|
|
||||||
'page' => $list->render(),
|
|
||||||
);
|
);
|
||||||
$this->assign($data);
|
|
||||||
$this->setMeta('用户行为');
|
|
||||||
return $this->fetch();
|
return $this->fetch();
|
||||||
}
|
}
|
||||||
|
|
||||||
+4
-4
@@ -28,11 +28,11 @@
|
|||||||
"liliuwei/thinkphp-jump": "^1.4",
|
"liliuwei/thinkphp-jump": "^1.4",
|
||||||
"sent/think-auth": "^1.2",
|
"sent/think-auth": "^1.2",
|
||||||
"topthink/think-captcha": "^3.0",
|
"topthink/think-captcha": "^3.0",
|
||||||
"sent/think-jwt": "^1.0",
|
"sent/think-jwt": "^1.0.0",
|
||||||
"xin/helper": "^1.0",
|
"xin/helper": "^1.0.0",
|
||||||
"sent/tree": "^1.0",
|
"sent/tree": "^1.0.0",
|
||||||
"lotofbadcode/phpspirit_dbskeleton": "^1.0",
|
"lotofbadcode/phpspirit_dbskeleton": "^1.0",
|
||||||
"sent/think-addons": "^1.0"
|
"sent/think-addons": "^1.0.0"
|
||||||
},
|
},
|
||||||
"require-dev": {
|
"require-dev": {
|
||||||
"symfony/var-dumper": "^4.2"
|
"symfony/var-dumper": "^4.2"
|
||||||
|
|||||||
@@ -1,32 +0,0 @@
|
|||||||
{extend name="admin/public/base"/}
|
|
||||||
{block name="body"}
|
|
||||||
<div class="main-box no-header clearfix">
|
|
||||||
<header class="main-box-header clearfix">
|
|
||||||
<!-- 标题栏 -->
|
|
||||||
<div class="pull-left">
|
|
||||||
<h2>{$meta_title}</h2>
|
|
||||||
</div>
|
|
||||||
<div class="pull-right">
|
|
||||||
</div>
|
|
||||||
</header>
|
|
||||||
|
|
||||||
<div class="main-box-body clearfix">
|
|
||||||
<table class="table table-striped">
|
|
||||||
<thead>
|
|
||||||
<tr>
|
|
||||||
<th align="right">名称</th>
|
|
||||||
<th>信息</th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
{volist name="info" id="item"}
|
|
||||||
<tr>
|
|
||||||
<td align="right">{$key}:</td>
|
|
||||||
<td>{$item}</td>
|
|
||||||
</tr>
|
|
||||||
{/volist}
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
{/block}
|
|
||||||
@@ -1,49 +0,0 @@
|
|||||||
{extend name="admin/public/base"/}
|
|
||||||
|
|
||||||
{block name="body"}
|
|
||||||
<div class="main-box no-header clearfix">
|
|
||||||
<header class="main-box-header clearfix">
|
|
||||||
<!-- 标题栏 -->
|
|
||||||
<div class="pull-left">
|
|
||||||
<h2>{$meta_title}</h2>
|
|
||||||
</div>
|
|
||||||
<div class="pull-right">
|
|
||||||
<a class="btn btn-warning ajax-get confirm" href="{:url('clear')}">清 空</a>
|
|
||||||
<button class="btn btn-danger ajax-post confirm" target-form="ids" url="{:url('dellog')}">删 除</button>
|
|
||||||
</div>
|
|
||||||
</header>
|
|
||||||
|
|
||||||
<div class="main-box-body clearfix">
|
|
||||||
<!-- 数据列表 -->
|
|
||||||
<table class="table table-striped">
|
|
||||||
<thead>
|
|
||||||
<tr>
|
|
||||||
<th class="row-selected row-selected"><input class="check-all" type="checkbox"/></th>
|
|
||||||
<th class="">编号</th>
|
|
||||||
<th class="">行为名称</th>
|
|
||||||
<th class="">执行者</th>
|
|
||||||
<th class="">执行时间</th>
|
|
||||||
<th class="">操作</th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
{volist name="list" id="vo"}
|
|
||||||
<tr>
|
|
||||||
<td><input class="ids" type="checkbox" name="id[]" value="{$vo['id']}" /></td>
|
|
||||||
<td>{$vo['id']} </td>
|
|
||||||
<td>{:get_action($vo['action_id'],'title')}</td>
|
|
||||||
<td>{:get_nickname($vo['user_id'])}</td>
|
|
||||||
<td><span>{$vo.create_time|time_format}</span></td>
|
|
||||||
<td><a href="{:url('detail?id='.$vo['id'])}">详细</a>
|
|
||||||
<a class="confirm ajax-get" href="{:url('dellog?id='.$vo['id'])}">删除</a>
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
{/volist}
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
<!-- 分页 -->
|
|
||||||
{$page|raw}
|
|
||||||
<!-- /分页 -->
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
{/block}
|
|
||||||
@@ -32,30 +32,6 @@
|
|||||||
</thead>
|
</thead>
|
||||||
<tbody>
|
<tbody>
|
||||||
{volist name="list" id="vo"}
|
{volist name="list" id="vo"}
|
||||||
<tr>
|
|
||||||
<td>
|
|
||||||
<input class="ids" type="checkbox" name="id[]" value="{$vo['id']}" />
|
|
||||||
</td>
|
|
||||||
<td>{$vo.id}</td>
|
|
||||||
<td>{$vo.name}</td>
|
|
||||||
<td>
|
|
||||||
<a href="{:url('edit?id='.$vo['id'])}">{$vo.title}</a>
|
|
||||||
</td>
|
|
||||||
<td>
|
|
||||||
<span>{:get_action_type($vo['type'])}</span>
|
|
||||||
</td>
|
|
||||||
<td>{$vo.remark}</td>
|
|
||||||
<td>{$vo.status_text}</td>
|
|
||||||
<td>
|
|
||||||
<a href="{:url('edit?id='.$vo['id'])}">编辑</a>
|
|
||||||
{if $vo['status']}
|
|
||||||
<a href="{:url('setstatus',array('id'=> $vo['id'],'status'=>0))}" class="ajax-get">禁用</a>
|
|
||||||
{else/}
|
|
||||||
<a href="{:url('setstatus',array('id'=> $vo['id'],'status'=>1))}" class="ajax-get">启用</a>
|
|
||||||
{/if}
|
|
||||||
<a href="{:url('del' , array('id' => $vo['id']))}" class="confirm ajax-get">删除</a>
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
{/volist}
|
{/volist}
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
Reference in New Issue
Block a user