| 1234567891011121314151617181920212223242526272829 |
- <?php
- namespace app\api\controller;
- use app\api\model\UserDynamicComment;
- use app\api\service\User as UserService;
- /**
- * 动态评论控制器
- * Class DynamicComment
- * @package app\api\controller
- */
- class DynamicComment extends Controller
- {
- public function list()
- {
- }
- public function message()
- {
- $model = new UserDynamicComment();
- $userInfo = UserService::getCurrentLoginUser(true);
- $userId = isset($userInfo['user_id'])? intval($userInfo['user_id']) : 0;
- $pageSize = $this->request->param('pageSize', 15);
- $list = $model->getListByUser($userId, $this->request->param(), (int)$pageSize);
- return $this->renderSuccess(compact('list'));
- }
- }
|