|
|
@@ -34,7 +34,15 @@ class ChatController extends BaseController
|
|
|
//发消息 shish 2019.12.28
|
|
|
public function actionSend()
|
|
|
{
|
|
|
- Gateway::sendToUid($uid, $dat);
|
|
|
+ $post = Yii::$app->request->post();
|
|
|
+ $msg = isset($post['msg']) ? $post['msg'] : '';
|
|
|
+
|
|
|
+ $m = json_encode(array(
|
|
|
+ 'type' => 'msg',
|
|
|
+ 'msg' => $msg,
|
|
|
+ ));
|
|
|
+
|
|
|
+ Gateway::sendToUid($uid, $m);
|
|
|
}
|
|
|
|
|
|
}
|