This commit is contained in:
2025-03-17 11:27:07 +08:00
parent 7a7f432006
commit 5febeca83f
6805 changed files with 6 additions and 6 deletions

View File

@@ -0,0 +1,34 @@
<?php
/*
* description
* authorwh
* email
* createTime{2024/4/5} {19:55}
*/
namespace app\api\controller;
class BaseWssApi extends BaseCommonController
{
/**
* descsocket专用json格式
*
* authorwh
* @param $action
* @param string $msg
* @param array $items
* @param string $method
* @return false|string
*/
static function json_wss($action,$msg='', $items=[], $method='response'){
$json = [
'action'=>$action,
'method'=>$method,
'msg'=>$msg,
'items'=>$items
];
return json_encode($json, JSON_UNESCAPED_UNICODE);
}
}