IndexController.php
1.4 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
<?php
// +----------------------------------------------------------------------
// | ThinkCMF [ WE CAN DO IT MORE SIMPLE ]
// +----------------------------------------------------------------------
// | Copyright (c) 2013-2017 http://www.thinkcmf.com All rights reserved.
// +----------------------------------------------------------------------
// | Author: pl125 <xskjs888@163.com>
// +----------------------------------------------------------------------
namespace api\demo\controller;
use cmf\controller\RestBaseController;
/**
* @title 测试demo
*/
class IndexController extends RestBaseController
{
/**
* @title 测试demo接口
* @description 接口说明
* @author 开发者
* @url /api/demo/index/index
* @method GET
*
* @header name:device require:1 default: desc:设备号
*
* @param name:id type:int require:1 default:1 other: desc:唯一ID
*
* @return name:名称
* @return mobile:手机号
* @return list_messages:消息列表@
* @list_messages message_id:消息ID content:消息内容
* @return object:对象信息@!
* @object attribute1:对象属性1 attribute2:对象属性2
* @return array:数组值#
* @return list_user:用户列表@
* @list_user name:名称 mobile:手机号 list_follow:关注列表@
* @list_follow user_id:用户id name:名称
*/
public function index()
{
$this->success('请求成功!', ['test'=>'test']);
}
}