public async Task NotifyThatCreatedAsync(IArmyNotificationService service) { var data = new ArmyNotificationDto { Squads = new List <SquadNotificationDto>() }; data.OwnerLogin = OwnerLogin; squads.ForEach(squad => squad.FillArmyData(data)); await service.NotifyThatCreatedAsync(data); }
public CommandsFactory(IArmyFactory armyFactory, IArmies armyRepository, IUsers usersRepository, IGetCurrentUserLoginStrategy currentUserLogin, IArmyNotificationService armyNotificationsService, ILog logger) { this.armyFactory = armyFactory; this.armyRepository = armyRepository; this.usersRepository = usersRepository; this.currentUserLogin = currentUserLogin; this.armyNotificationsService = armyNotificationsService; this.logger = logger; }
public CreateArmyCommand(IArmyFactory armyFactory, IArmies armyRepository, IGetCurrentUserLoginStrategy currentUserLogin, IArmyNotificationService armyNotificationsService, ILog logger, ArmyPostDto data) { this.armyFactory = armyFactory; this.armyRepository = armyRepository; this.currentUserLogin = currentUserLogin; this.armyNotificationsService = armyNotificationsService; this.logger = logger; this.data = data; }