DiverseYouthNightSchool/application/admin/controller/csmtable/Datasource.php

35 lines
783 B
PHP
Raw Normal View History

2024-11-04 10:49:10 +08:00
<?php
namespace app\admin\controller\csmtable;
use app\common\controller\Backend;
/**
* 管理员管理
*
* @icon fa fa-users
* @remark 一个管理员可以有多个角色组,左侧的菜单根据管理员所拥有的权限进行生成
*/
class Datasource extends Backend
{
// protected $noNeedLogin = ["*"];
// protected $noNeedRight = ["*"];
/**
* 代替 /auth/admin
*
* 地址: /csmtable/datasource/admin
*/
public function admin()
{
$filter = $this->request->get("filter", '');
$filter = (array)json_decode($filter, true);
$dao = new \app\admin\model\Admin();
$list = $dao->where("id","in",$filter['id'])->field("id,nickname")->select();
return json(['rows' => $list]);
}
}