public void DeletePosition(DTOPosition position) { if (PositionListChanged != null) { PositionListChanged.Invoke(this, new PositionListChangedEventArgs(Positions)); } }
public void UpdatePosition(Domain.DTO.Position position) { var updatingPosition = Positions.Find(p => p.Id == position.Id); var index = Positions.IndexOf(updatingPosition); Positions[index] = position; PositionListChanged?.Invoke(this, new PositionListChangedEventArgs(Positions, null)); }
public void LoadPositionList() { var repository = new PositionRepositoryStub(); var mapper = new Mapper(); Positions = mapper.GetDTOPositionList(repository.LoadPositions()); PositionListChanged?.Invoke(this, new PositionListChangedEventArgs(Positions, null)); }
private void InvokeEvent() { PositionListChanged?.Invoke(this, new PositionListChangedEventArgs(Positions, null)); }
public void DeletePosition(Domain.DTO.Position position) { Positions.Remove(position); PositionListChanged?.Invoke(this, new PositionListChangedEventArgs(Positions, null)); }
public void AddPosition(Domain.DTO.Position position) { Positions.Add(position); PositionListChanged?.Invoke(this, new PositionListChangedEventArgs(Positions, null)); }
public void UpdatePosition(DTO.Position position) { PositionListChanged?.Invoke(this, new PositionListChangedEventArgs(Positions, null)); }
private void OnPositionListChange(object sender, PositionListChangedEventArgs e) { PositionListChanged?.Invoke(this, new PositionListChangedEventArgs(e.Positions, e.Error)); }
private void ThrowError(string error) { PositionListChanged?.Invoke(this, new PositionListChangedEventArgs(Positions, error)); }