默认输出类型 为 json

This commit is contained in:
何秀钢 2019-10-02 23:06:04 +08:00
parent 2fc82f7acf
commit 5c494bc01f
2 changed files with 4 additions and 4 deletions

View File

@ -30,7 +30,7 @@ class Base extends Controller {
$return['debug'] = $this->debug;
}
return json($return);
return $return;
}
public function buildFailed($code, $msg, $data = []) {
@ -43,7 +43,7 @@ class Base extends Controller {
$return['debug'] = $this->debug;
}
return json($return);
return $return;
}
protected function debug($data) {

View File

@ -27,7 +27,7 @@ class Base extends Controller {
'data' => $data
];
return json($return);
return $return;
}
public function buildFailed($code, $msg, $data = []) {
@ -37,7 +37,7 @@ class Base extends Controller {
'data' => $data
];
return json($return);
return $return;
}
}