api/app/controller/Index.php
2019-06-22 22:03:22 +08:00

30 lines
524 B
PHP

<?php
namespace app\controller;
use app\BaseController;
use think\facade\Config;
use think\response\Json;
class Index extends BaseController
{
public function index()
{
return Json::create([
"code" => 0,
"message" => "running"
]);
}
public function test($name = 'ThinkPHP6')
{
return \json(
Config::get("app.evaluation.subject")
);
}
public function hello($name = 'ThinkPHP6')
{
return 'hello,' . $name;
}
}