12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697 |
- <?php
- // +----------------------------------------------------------------------
- // | ThinkAdmin
- // +----------------------------------------------------------------------
- // | 版权所有 2014~2022 广州楚才信息科技有限公司 [ http://www.cuci.cc ]
- // +----------------------------------------------------------------------
- // | 官方网站: https://thinkadmin.top
- // +----------------------------------------------------------------------
- // | 开源协议 ( https://mit-license.org )
- // | 免费声明 ( https://thinkadmin.top/disclaimer )
- // +----------------------------------------------------------------------
- // | gitee 代码仓库:https://gitee.com/zoujingli/ThinkAdmin
- // | github 代码仓库:https://github.com/zoujingli/ThinkAdmin
- // +----------------------------------------------------------------------
- namespace app\admin\controller;
- use app\data\model\DataFeedback;
- use app\data\model\DataPoolTalent;
- use app\data\model\DataTeachingKnowledge;
- use app\data\model\DataZhicheng;
- use Carbon\Carbon;
- use think\admin\Controller;
- use app\data\model\SystemUser;
- use think\Db;
- use think\db\Query;
- /**
- * 用户反馈列表
- * Class PoolTalent
- * @package app\admin\controller
- */
- class Feedback extends Controller
- {
- /**
- * 用户反馈列表
- * @auth true
- * @menu true
- */
- public function index(){
- $this->title='用户反馈列表';
- $phone=input('phone');
- DataFeedback::mQuery()
- ->when($phone,function (Query $query) use ($phone) {
- $query->hasWhere('user',function (Query $query) use ($phone) {
- $query->whereLike('phone',"%{$phone}%");
- });
- })
- ->like('content')
- ->with(['user','reply'])
- ->where('pid',0)
- ->where('is_del',1)
- ->order('id','desc')
- ->layTable();
- }
- protected function _index_page_filter(&$data)
- {
- }
- /**
- * 回复
- * @auth true
- * @menu true
- */
- public function reply(){
- DataFeedback::mForm('form');
- }
- public function _form_filter($vo){
- if ($this->request->isGet()) {
- }elseif ($this->request->isPost()){
- $data = [
- 'uuid'=>0,
- 'pid'=>$vo['id'],
- 'content'=>$vo['content'],
- ];
- DataFeedback::create($data);
- $this->success('回复成功');
- }
- }
- /**
- * 删除
- * @auth true
- * @menu true
- */
- public function del($id){
- DataFeedback::whereIn('id',$id)->save([
- 'is_del'=>0,
- ]);
- $this->success('删除成功');
- }
- }
|