作者 wangzhi

jiekou 同步

不能预览此文件类型
<?php
namespace app\api\controller;
use app\common\controller\Api;
use think\Db;
/**
* 六期新增接口
*/
class Six extends Api
{
protected $noNeedLogin = ['*'];
protected $noNeedRight = ['*'];
/**
* @ApiTitle (机型-下拉菜单)
* @ApiMethod (POST)
* @ApiParams (name="base_id", type="integer", required=true, description="基地ID")
* @ApiReturn ({
'code':'1',
'msg':'返回成功',
"data": [
{
"id": 15,
"title": "R22直升机" //飞机名称
}
]
})
*/
public function SelectPage()
{
$BaseId = $this->request->post('base_id');
if (!isset($BaseId) || $BaseId == 0) $this->error('基地ID不能为空');
$this->success('SUCCESS', Db::name('plane')->where('base_id', $BaseId)->field('id,title')->select());
}
}
\ No newline at end of file
... ...
... ... @@ -585,6 +585,7 @@ class Api
/**
* @ApiInternal
* 分页
*/
function page_array($count, $page, $array, $order)
... ...