* Further improvements to generate PackList

This commit is contained in:
2025-05-17 18:36:11 +02:00
parent bc28c5d63d
commit 6ab3960e50
20 changed files with 671 additions and 191 deletions

View File

@@ -18,4 +18,19 @@ public class WzRowMeyleService(SytelineSaAppDbContext context, IMapper mapper) :
await context.WzRowsMeyle.AddRangeAsync(entities);
await context.SaveChangesAsync();
}
public async Task<IEnumerable<WzRowMeyleDto>> GetByWzHeaderId(Guid wzHeaderId)
{
return await context.WzRowsMeyle
.Where(x => x.FK_Header == wzHeaderId)
.Select(x => mapper.Map<WzRowMeyleDto>(x))
.ToListAsync();
}
public async Task UpdateRows(IEnumerable<WzRowMeyleDto> rows)
{
var entities = mapper.Map<IEnumerable<WzRowMeyle>>(rows);
context.WzRowsMeyle.UpdateRange(entities);
await context.SaveChangesAsync();
}
}