request->getServerParam('HTTP_AUTHORIZATION'); if (!empty($authorization)) { self::getUserIdByAuthorization(); } $this->objMSystemPushMessage = new MSystemPushMessage($this->onlineUserId, $this->onlineEnterpriseId); } /** * 获取对应推送模板的推送信息 */ public function getSettingDataByMessageIds() { $params = $this->request->getRawJson(); if (empty($params)) { $this->sendOutput('参数为空', ErrorCode::$paramError); } $selectParams = [ 'id' => getArrayItem($params, 'id', []), ]; foreach ($selectParams as $key => $value) { if (empty($value)) { $this->sendOutput($key . '参数错误', ErrorCode::$paramError); } } $result = $this->objMSystemPushMessage->getSettingDataByMessageIds($selectParams); if($result->isSuccess()){ $this->sendOutput($result->getData()); }else{ $this->sendOutput($result->getData(), $result->getErrorCode()); } } }