wankeda
3 天以前 d4b029d2697c265fd575549db79cd55bb4f9532e
1
2
3
4
5
6
7
8
9
10
11
12
13
using Microsoft.AspNetCore.SignalR;
 
namespace WIDESEA_Model
{
    public class WMSNoticeHub : Hub
    {
        // 前端监听这个方法就能收到消息
        public async Task SendMessage(string message)
        {
            await Clients.All.SendAsync("ReceiveMessage", message);
        }
    }
}