public async Task <Batch> UpdateBatchAsync( [GraphQLType(typeof(UpdateBatchInputType))][GraphQLName("input")] UpdateBatchCommand input, [Service] ISheaftMediatr mediatr, BatchesByIdBatchDataLoader catalogsDataLoader, CancellationToken token) { await ExecuteAsync(mediatr, input, token); return(await catalogsDataLoader.LoadAsync(input.BatchId, token)); }
public async Task <Batch> CreateBatchAsync( [GraphQLType(typeof(CreateBatchInputType))][GraphQLName("input")] CreateBatchCommand input, [Service] ISheaftMediatr mediatr, BatchesByIdBatchDataLoader catalogsDataLoader, CancellationToken token) { var result = await ExecuteAsync <CreateBatchCommand, Guid>(mediatr, input, token); return(await catalogsDataLoader.LoadAsync(result, token)); }