Ejemplo n.º 1
0
     private void FixupStation(Station previousValue)
     {
         if (previousValue != null && previousValue.Tests.Contains(this))
         {
             previousValue.Tests.Remove(this);
         }
 
         if (Station != null)
         {
             if (!Station.Tests.Contains(this))
             {
                 Station.Tests.Add(this);
             }
         }
     }
Ejemplo n.º 2
0
 /// <summary>
 /// Initializes a new instance of the <see cref="ProductVM"/> class from the model.
 /// </summary>
 /// <param name="entity">The model.</param>
 /// <param name="access"></param>
 public StationVM(Station entity, AccessType access, StationDataService dataService)
     : base(access)
 {
     InitializeData(dataService);
     _model = entity;
 }
Ejemplo n.º 3
0
 public override void Save(object param)
 {
     StationDataService.AttachModel(_model);
     _model = StationDataService.GetSingle(_model.Id); OnPropertyChanged("ModifiedBy");OnPropertyChanged("ModifiedDate");Mode = ModificationStatus.Saved;
 }
Ejemplo n.º 4
0
 /// <summary>
 /// Initializes a new instance of the <see cref="StationInfoVM"/> class from the model.
 /// </summary>
 /// <param name="entity">The model.</param>
 public StationInfoVM(Station entity)
 {
     _model = entity;
 }