ChatController.php 497 B

1234567891011121314151617181920212223242526272829
  1. <?php
  2. namespace client\controllers;
  3. use Yii;
  4. use yii\web\Controller;
  5. use common\components\util;
  6. class ChatController extends BaseController
  7. {
  8. //聊天首页,前端使用
  9. public function actionIndex()
  10. {
  11. return $this->renderPartial('index');
  12. }
  13. //绑定 shish 2019.12.28
  14. public function actionBind()
  15. {
  16. $post = Yii::$app->request->post();
  17. $clientId = isset($post['clientId']) ? $post['clientId'] : '';
  18. $userId = $this->userId;
  19. Gateway::bindUid($client_id, $userId);
  20. }
  21. }