作者 王智

文档修改

... ... @@ -341,16 +341,34 @@ class Common extends Api
$Info = Db::name('area')->where('pid', 0)->select();
$this->success('成功', $Info);
}
//市
public function BroAddress(){
$Pid=input('pid');
public function BroAddress()
{
$Pid = input('pid');
$Info = Db::name('area')->where('pid', $Pid)->select();
$this->success('成功', $Info);
}
//区
public function BroStree(){
$Pid=input('pid');
public function BroStree()
{
$Pid = input('pid');
$Info = Db::name('area')->where('pid', $Pid)->select();
$this->success('成功', $Info);
}
//定时任务
public function OverTime()
{
$Info = Db::name('clock_user')->where('exp_time', '<', time())->select();
foreach ($Info as $k => $v) {
$Count = Db::name('clock_help')->where('clock_id', $v['id'])->select();
if (count($Count) != 3) {
Db::name('clock_help')->where('clock_id', $v['id'])->delete();
Db::name('clock_user')->where('id', $v['id'])->update(['exp_time' => time() + 60 * 60 * 2]);
}
}
}
}
... ...