fix: update workshop identification logic in InstitutionContractApplication
This commit is contained in:
@@ -1557,17 +1557,22 @@ public class InstitutionContractApplication : IInstitutionContractApplication
|
||||
var currentWorkshops = institutionContract.WorkshopGroup.CurrentWorkshops.ToList();
|
||||
foreach (var createdWorkshop in initialCreatedWorkshops)
|
||||
{
|
||||
if (currentWorkshops.Any(x => x.InitialWorkshopId == createdWorkshop.id))
|
||||
if (currentWorkshops.Any(x => x.WorkshopId == createdWorkshop.WorkshopId))
|
||||
{
|
||||
continue;
|
||||
|
||||
}
|
||||
|
||||
var currentWorkshop = new InstitutionContractWorkshopCurrent(createdWorkshop.WorkshopName,
|
||||
createdWorkshop.Services.RollCall, createdWorkshop.Services.RollCallInPerson,
|
||||
createdWorkshop.Services.CustomizeCheckout, createdWorkshop.Services.Contract,
|
||||
createdWorkshop.Services.ContractInPerson, createdWorkshop.Services.Insurance,
|
||||
createdWorkshop.Services.ContractInPerson, createdWorkshop.Services.Insurance,
|
||||
createdWorkshop.Services.InsuranceInPerson,createdWorkshop.PersonnelCount, createdWorkshop.Price,
|
||||
createdWorkshop.InstitutionContractWorkshopGroupId,createdWorkshop.WorkshopGroup,
|
||||
createdWorkshop.WorkshopId!.Value, createdWorkshop.id);
|
||||
institutionContract.WorkshopGroup.AddCurrentWorkshop(currentWorkshop);
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
if (institutionContract.WorkshopGroup.InitialWorkshops.All(x => x.WorkshopCreated && x.WorkshopId is > 0))
|
||||
|
||||
Reference in New Issue
Block a user