123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362 |
- <?php
- namespace App\Http\Controllers\User;
- use App\Http\Controllers\BaseController;
- use App\Http\Logic\User\UserLogic;
- class UserController extends BaseController
- {
- /**
- * @SWG\Get(
- * path="/user/info",
- * tags={"用户管理"},
- * summary="获取用户信息",
- * description="获取用户信息接口",
- * produces={"application/json"},
- * @SWG\Response(
- * response="200",
- * description="success",
- * @SWG\Schema(
- * @SWG\Property(
- * property="user_head_img_url",
- * type="string",
- * description="用户头像"
- * ),
- * @SWG\Property(
- * property="user_nickname",
- * type="string",
- * description="用户昵称"
- * ),
- * @SWG\Property(
- * property="user_sex",
- * type="string",
- * description="用户性别"
- * ),
- * @SWG\Property(
- * property="user_balance",
- * type="string",
- * description="'用户可提现余额(单位为分)"
- * ),
- * @SWG\Property(
- * property="user_unreceive_balance",
- * type="string",
- * description="用户未结算金额(单位为分"
- * ),
- * @SWG\Property(
- * property="user_ucrash_balance",
- * type="string",
- * description="用户累计提现金额(单位为分"
- * ),
- * @SWG\Property(
- * property="created_at",
- * type="string",
- * description="'注册时间"
- * ),
- * @SWG\Property(
- * property="user_fans_num",
- * type="string",
- * description="'用户粉丝数量"
- * ),
- * @SWG\Property(
- * property="last_month_money",
- * type="string",
- * description="'上月预估收益"
- * ),
- * @SWG\Property(
- * property="month_money",
- * type="string",
- * description="'本月预估收益"
- * )
- * )
- * ),
- * @SWG\Response(
- * response="403",
- * description="fail",
- * @SWG\Schema(ref="#/definitions/ErrorBean")
- * )
- * )
- */
- public function getUserInfo()
- {
- $data = UserLogic::getUserInfoLogic();
- return $this->success($data);
- }
- /**
- * @SWG\Post(
- * path="/user/fans/list",
- * tags={"用户管理"},
- * summary="用户粉丝列表接口",
- * description="用户粉丝列表接口",
- * produces={"application/json"},
- * @SWG\Parameter(
- * name="page",
- * in="query",
- * description="第几页",
- * type="string"
- * ),
- * @SWG\Parameter(
- * name="page_size",
- * in="query",
- * description="每页数量",
- * type="string"
- * ),
- * @SWG\Parameter(
- * name="type",
- * in="query",
- * description="粉丝类型(1未激活2已激活)",
- * type="string"
- * ),
- * @SWG\Response(
- * response="200",
- * description="success",
- * @SWG\Schema(ref="#/definitions/GetFansListResultBean")
- * ),
- * @SWG\Response(
- * response="403",
- * description="fail",
- * @SWG\Schema(ref="#/definitions/ErrorBean")
- * )
- * )
- */
- public function getFansList()
- {
- $datas = UserLogic::getFansListLogic();
- return $this->success($datas);
- }
- /**
- * @SWG\Get(
- * path="/user/fianance/list",
- * tags={"用户管理"},
- * summary="收支明细列表接口",
- * description="收支明细列表接口",
- * produces={"application/json"},
- * @SWG\Parameter(
- * name="page",
- * in="query",
- * description="第几页",
- * type="string"
- * ),
- * @SWG\Parameter(
- * name="page_size",
- * in="query",
- * description="每页数量",
- * type="string"
- * ),
- * @SWG\Parameter(
- * name="finance_type",
- * in="query",
- * description="流水类型(0全部1收入2提现)",
- * type="string"
- * ),
- * @SWG\Response(
- * response="200",
- * description="success",
- * @SWG\Schema(
- * @SWG\Property(
- * property="total",
- * type="string",
- * description="总数量"
- * ),
- * @SWG\Property(
- * property="list",
- * type="array",
- * description="数据",
- * @SWG\Items(
- * @SWG\Property(
- * property="finance_balance",
- * type="string",
- * description="流水金额(单位为分)"
- * ),
- * @SWG\Property(
- * property="finance_type",
- * type="string",
- * description="流水类型(1收入2支出)"
- * ),
- * @SWG\Property(
- * property="finance_number",
- * type="string",
- * description="流水编号"
- * ),
- * @SWG\Property(
- * property="created_at",
- * type="string",
- * description="创建时间"
- * ),
- * @SWG\Property(
- * property="cash_status",
- * type="string",
- * description="提现状态(0提现中1已到账2提现失败)"
- * )
- * )
- * ),
- * )
- * ),
- * @SWG\Response(
- * response="403",
- * description="fail",
- * @SWG\Schema(ref="#/definitions/ErrorBean")
- * )
- * )
- */
- public function getFinanceList()
- {
- $datas = UserLogic::getFinanceListLogic();
- return $this->success($datas);
- }
- /**
- * @SWG\Get(
- * path="/user/fianance/detail",
- * tags={"用户管理"},
- * summary="流水详情接口",
- * description="流水详情接口",
- * produces={"application/json"},
- * @SWG\Parameter(
- * name="id",
- * in="query",
- * description="流水ID",
- * type="string"
- * ),
- * @SWG\Response(
- * response="200",
- * description="success",
- * @SWG\Schema(
- * @SWG\Property(
- * property="finance_balance",
- * type="string",
- * description="流水金额"
- * ),
- * @SWG\Property(
- * property="finance_remark",
- * type="string",
- * description="流水备注"
- * ),
- * @SWG\Property(
- * property="finance_number",
- * type="string",
- * description="流水备注"
- * ),
- * @SWG\Property(
- * property="created_at",
- * type="string",
- * description="创建时间"
- * ),
- * @SWG\Property(
- * property="cash_status",
- * type="string",
- * description="提现状态(0提现中1已到账2提现失败)"
- * )
- * )
- * ),
- * @SWG\Response(
- * response="403",
- * description="fail",
- * @SWG\Schema(ref="#/definitions/ErrorBean")
- * )
- * )
- */
- public function getFinanceDetail()
- {
- $datas = UserLogic::getFinanceDetailLogic();
- return $this->success($datas);
- }
- /**
- * @SWG\Post(
- * path="/user/cash",
- * tags={"用户管理"},
- * summary="提现接口",
- * description="提现接口",
- * produces={"application/json"},
- * @SWG\Parameter(
- * name="amount",
- * in="query",
- * description="提现金额",
- * type="string"
- * ),
- * @SWG\Response(
- * response="200",
- * description="success",
- * @SWG\Schema(ref="#/definitions/SuccessBean")
- * ),
- * @SWG\Response(
- * response="403",
- * description="fail",
- * @SWG\Schema(ref="#/definitions/ErrorBean")
- * )
- * )
- */
- public function getCash()
- {
- UserLogic::getCashLogic();
- return $this->success([],200,"提现成功");
- }
- /**
- * @SWG\Get(
- * path="/user/recommend/url",
- * tags={"用户管理"},
- * summary="获取用户推广二维码接口",
- * description="获取用户推广二维码接口",
- * produces={"application/json"},
- * @SWG\Response(
- * response="200",
- * description="success",
- * @SWG\Schema(
- * @SWG\Property(
- * property="url",
- * type="string",
- * description="推广地址"
- * )
- * )
- * ),
- * @SWG\Response(
- * response="403",
- * description="fail",
- * @SWG\Schema(ref="#/definitions/ErrorBean")
- * )
- * )
- */
- public function getRecommendUrl()
- {
- $data = UserLogic::getRecommendUrlLogic();
- return $this->success($data);
- }
- /**
- * @SWG\Post(
- * path="/user/feedback",
- * tags={"用户管理"},
- * summary="反馈接口",
- * description="反馈接口",
- * produces={"application/json"},
- * @SWG\Parameter(
- * name="content",
- * in="query",
- * description="反馈内容",
- * type="string"
- * ),
- * @SWG\Response(
- * response="200",
- * description="success",
- * @SWG\Schema(ref="#/definitions/SuccessBean")
- * ),
- * @SWG\Response(
- * response="403",
- * description="fail",
- * @SWG\Schema(ref="#/definitions/ErrorBean")
- * )
- * )
- */
- public function feedback()
- {
- UserLogic::feedbackLogic();
- return $this->success();
- }
- }
|