diff options
| author | Avi Levkovich <avi@twine-s.com> | 2020-07-13 18:26:20 +0300 |
|---|---|---|
| committer | Avi Levkovich <avi@twine-s.com> | 2020-07-13 18:26:20 +0300 |
| commit | 6908c13314f00030dd039d003aaf6193bdb0f28b (patch) | |
| tree | 5eee7e648541f0f1f971a9e7a33614bacd0adf1a /Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/ViewModels | |
| parent | 5f72798aaff5d2200c939f522bcc92ff7471d2af (diff) | |
| parent | ebdba4dd5bb09f3bbefcd774931153346041dabc (diff) | |
| download | Tango-6908c13314f00030dd039d003aaf6193bdb0f28b.tar.gz Tango-6908c13314f00030dd039d003aaf6193bdb0f28b.zip | |
merge
Diffstat (limited to 'Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/ViewModels')
| -rw-r--r-- | Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/ViewModels/MainViewVM.cs | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/ViewModels/MainViewVM.cs b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/ViewModels/MainViewVM.cs index eed594718..01def8679 100644 --- a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/ViewModels/MainViewVM.cs +++ b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/ViewModels/MainViewVM.cs @@ -2321,7 +2321,13 @@ namespace Tango.MachineStudio.Developer.ViewModels return; } SelectedSegment.BrushStops.Remove(x); - _activeJobDbContext.BrushStops.Remove(x); + var existingBrushStop = _activeJobDbContext.BrushStops.FirstOrDefault(y => y.Guid == x.Guid); + if(existingBrushStop != null) + { + _activeJobDbContext.BrushStops.Remove(existingBrushStop); + } + + }); ArrangeBrushStopsIndices(); @@ -2356,6 +2362,7 @@ namespace Tango.MachineStudio.Developer.ViewModels stop.SetAllDispensingStepDivisions(BL.Dispensing.DispenserStepDivisions.D8); stop.SetLiquidVolumes(SelectedMachine.Configuration, SelectedRML, SelectedProcessParametersTable); SelectedSegment.BrushStops.Add(stop); + // _activeJobDbContext.BrushStops.Add(stop); SelectedSegment.BrushStops.ToList().ForEach(x => x.RaiseOffsetChanged()); ArrangeBrushStopsIndices(); } |
