Add calendar integrations and collaboration updates
Some checks failed
Backend CI/CD / build_and_deploy (push) Has been cancelled
Frontend CI/CD / build_and_deploy (push) Has been cancelled

This commit is contained in:
2026-05-05 15:25:53 -04:00
parent c49f03ec06
commit b66c10b681
82 changed files with 8420 additions and 2048 deletions

View File

@@ -0,0 +1,31 @@
using Socialize.Api.Data;
using Socialize.Api.Modules.ContentItems.Contracts;
using Socialize.Api.Modules.ContentItems.Data;
namespace Socialize.Api.Modules.ContentItems.Services;
public class ContentItemActivityWriter(
AppDbContext dbContext)
: IContentItemActivityWriter
{
public async Task WriteAsync(ContentItemActivityWriteModel model, CancellationToken cancellationToken = default)
{
ContentItemActivityEntry entry = new()
{
Id = Guid.NewGuid(),
WorkspaceId = model.WorkspaceId,
ContentItemId = model.ContentItemId,
EventType = model.EventType,
EntityType = model.EntityType,
EntityId = model.EntityId,
Summary = model.Summary,
ActorUserId = model.ActorUserId,
ActorEmail = model.ActorEmail,
MetadataJson = model.MetadataJson,
CreatedAt = DateTimeOffset.UtcNow,
};
dbContext.ContentItemActivityEntries.Add(entry);
await dbContext.SaveChangesAsync(cancellationToken);
}
}