private void RemoveExecute() { if (ListClients.Count < IdToRemove + 1) return; var cl = new Client { Id = ListClients[IdToRemove + 1].Id, Name = ListClients[IdToRemove + 1].Name, CreationDate = ListClients[IdToRemove + 1].CreationDate }; _eventAggregator.GetEvent<RemoveClientEvent>().Publish(cl); }
private void ClientUpdated(Client obj) { Client = obj; Clients.Add(obj); _eventAggregator.GetEvent<UpdateListClientEvent>().Publish(_clients); }
private void Execute() { LastUpdate = DateTime.Now; var cl = new Client { Id = CountList + 1, Name = FirstName, CreationDate = DateTime.Now }; _eventAggregator.GetEvent<UpdateEvent>().Publish(LastUpdate.ToString()); _eventAggregator.GetEvent<UpdateClientEvent>().Publish(cl); }