后端文件更新
This commit is contained in:
@@ -23,9 +23,9 @@ class Client extends Admin{
|
||||
'query' => $this->request->param()
|
||||
));
|
||||
|
||||
$data = $res->toArray();
|
||||
$data['list'] = $res;
|
||||
$data['page'] = $res->render();
|
||||
$this->data = $data;
|
||||
$this->data['data'] = $data;
|
||||
return $this->data;
|
||||
}
|
||||
|
||||
|
||||
@@ -52,7 +52,16 @@ class Config extends Admin {
|
||||
*/
|
||||
public function group(ConfigModel $config) {
|
||||
if ($this->request->isAjax()) {
|
||||
$this->data['code'] = 1;
|
||||
$data = $this->request->param();
|
||||
$result = $config->updateConfig($data);
|
||||
|
||||
if (false !== $result) {
|
||||
$this->data['code'] = 0;
|
||||
$this->data['msg'] = "更新成功!";
|
||||
}else{
|
||||
$this->data['code'] = 1;
|
||||
$this->data['msg'] = $config->error;
|
||||
}
|
||||
return $this->data;
|
||||
} else {
|
||||
$id = $this->request->param('id', 1);
|
||||
|
||||
Reference in New Issue
Block a user