Merge branch 'master' of https://git.yuzhankeji.cn/linyiman/heping-api
This commit is contained in:
24
app/controller/About.php
Normal file
24
app/controller/About.php
Normal file
@@ -0,0 +1,24 @@
|
|||||||
|
<?php
|
||||||
|
namespace app\controller;
|
||||||
|
|
||||||
|
use think\facade\Db;
|
||||||
|
|
||||||
|
class About
|
||||||
|
{
|
||||||
|
public function rule()
|
||||||
|
{
|
||||||
|
$info = Db::name("config")->where("name", "rule")->find();
|
||||||
|
if (empty($info) || empty($info['value'])) {
|
||||||
|
return show("用户协议未设置");
|
||||||
|
}
|
||||||
|
return show("获取成功", SUCCESS_CODE, ["content" => $info["value"]]);
|
||||||
|
}
|
||||||
|
public function privacy()
|
||||||
|
{
|
||||||
|
$info = Db::name("config")->where("name", "yszc")->find();
|
||||||
|
if (empty($info) || empty($info['value'])) {
|
||||||
|
return show("隐私政策未设置");
|
||||||
|
}
|
||||||
|
return show("获取成功", SUCCESS_CODE, ["content" => $info["value"]]);
|
||||||
|
}
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user