后端:

1、事件订阅增加rabbitmq中间件
移动端:
1、完善移动端目录结构和代码框架
This commit is contained in:
2026-01-28 18:19:45 +08:00
47 changed files with 821 additions and 265 deletions
@@ -0,0 +1,13 @@
using IM_API.Domain.Events;
using MassTransit;
namespace IM_API.Application.EventHandlers.FriendAddHandler
{
public class FriendAddConversationHandler : IConsumer<FriendAddEvent>
{
public Task Consume(ConsumeContext<FriendAddEvent> context)
{
throw new NotImplementedException();
}
}
}
@@ -0,0 +1,31 @@
using IM_API.Domain.Events;
using IM_API.Models;
using MassTransit;
namespace IM_API.Application.EventHandlers.FriendAddHandler
{
public class FriendAddSignalRHandler : IConsumer<FriendAddEvent>
{
private readonly ImContext _context;
public FriendAddSignalRHandler(ImContext context)
{
_context = context;
}
public Task Consume(ConsumeContext<FriendAddEvent> context)
{
throw new NotImplementedException();
var @event = context.Message;
var RequestfriendShip = new Friend()
{
Avatar = @event.ResponseUser.Avatar,
UserId = @event.RequestUser.Id,
RemarkName = @event.RequestInfo.NickName,
Created = @event.RequestInfo.Created,
};
}
}
}