feat(dal, TemplateDistributorWorker): NextRunServiceV2 - реализован метод распределения шаблонов. Обновлен TemplateDistributorWorker для использования новой логики.

This commit is contained in:
Mikhail Trubnikov
2026-02-13 15:39:21 +10:00
parent 858dd8c31c
commit 89b6cdf731
7 changed files with 234 additions and 46 deletions

View File

@@ -1,4 +1,5 @@
using PARR.DAL.DomainServices.Shortcodes;
using PARR.Constants;
using PARR.DAL.DomainServices.Shortcodes;
using PARR.DAL.NextRunServices;
using PARR.DAL.NextRunServices.Models;
using PARR.DAL.NextRunServices.Subservices;
@@ -17,8 +18,8 @@ namespace PARR.Test.NextRun
public NextRunTest(
/*ITemplateDistributor templateDistributor, */
INextRunService nextRunService,
ITemplateService templateService,
INextRunService nextRunService,
ITemplateService templateService,
IShortcodesService shortcodesService,
ITemplateDistributorV2 templateDistributorV2,
INextRunServiceV2 nextRunServiceV2
@@ -32,13 +33,13 @@ namespace PARR.Test.NextRun
this.nextRunServiceV2 = nextRunServiceV2;
}
public async Task Test()
{
#region тестирование INextRunServiceV2
var distributeResult = await nextRunServiceV2.GetNextRunForJobGroupWithAutoDistributionAsync(Guid.Parse("d25d8a9e-898f-417a-9bec-ef3a356e7c94"));
var distributeResult = await nextRunServiceV2.GetNextRunForJobGroupWithAutoDistributionAsync(Guid.Parse("d25d8a9e-898f-417a-9bec-ef3a356e7c94"), TemplateStatusTypeEnum.Used);
#endregion