public async Task <bool> UpdateActionCloseUI(ActionCallbackUIModel actionCloseUIUpdate) { RestRequest request = await PrepareQuery("SignalR/Response/ActionClose", Method.PUT); request.AddParameter("application/json", JsonConvert.SerializeObject(actionCloseUIUpdate), ParameterType.RequestBody); var queryResult = await _client.ExecuteTaskAsync(request); if (!queryResult.IsSuccessful) { _logger.LogError($"UpdateActionCloseUI: Error while sending a message: {queryResult.StatusCode}"); return(false); } return(true); }
public async Task <IActionResult> UpdateActionCallbackUI([FromBody] ActionCallbackUIModel actionCallbackUIUpdate) { await _hub.Clients.All.SendAsync("UpdateActionCallbackUI", actionCallbackUIUpdate); return(Ok()); }