return postdto from post create

This commit is contained in:
john 2025-05-28 20:05:00 +02:00
parent 8ad4302ec8
commit d1687f276b
15 changed files with 226 additions and 111 deletions

View file

@ -1,8 +1,22 @@
using Femto.Common;
using Femto.Common.Domain;
using Femto.Modules.Blog.Application.Queries.GetPosts.Dto;
namespace Femto.Modules.Blog.Application.Commands.CreatePost;
public record CreatePostCommand(Guid AuthorId, string Content, IEnumerable<CreatePostMedia> Media, bool? IsPublic)
: ICommand<Guid>;
public record CreatePostCommand(
Guid AuthorId,
string Content,
IEnumerable<CreatePostMedia> Media,
bool? IsPublic,
CurrentUser CurrentUser
) : ICommand<PostDto>;
public record CreatePostMedia(Guid MediaId, Uri Url, string? Type, int Order, int? Width, int? Height);
public record CreatePostMedia(
Guid MediaId,
Uri Url,
string? Type,
int Order,
int? Width,
int? Height
);