28 lines
487 B
PHP
28 lines
487 B
PHP
<?php
|
|
|
|
namespace app\controller\api;
|
|
|
|
use think\facade\Db;
|
|
use app\model\Area as AreaModel;
|
|
/**
|
|
* Area
|
|
*
|
|
* Class Business
|
|
* @package app\controller\api
|
|
*/
|
|
class Area extends Base
|
|
{
|
|
protected $noNeedLogin = [
|
|
'index',
|
|
];
|
|
|
|
/**
|
|
* 根据上级行政代码 获取下级
|
|
* */
|
|
public function index()
|
|
{
|
|
$pcode = input("areaId/d",86);
|
|
$filter = input("filter",false);
|
|
return json(AreaModel::getByPCode($pcode,$filter));
|
|
}
|
|
} |