// sostituire foratura semplice con classe base per forature o in caso con interfaccia
        public ForaturaPatternSelectionViewModel(IForaturaPatternable foratura, EditWorkViewModel viewModelEditWorkParent)
            : base("Pattern Selection", viewModelEditWorkParent)
        {
            _foraturaSemplice = foratura;

            PatternParameter = GetViewModel(_foraturaSemplice.PatternDrilling);
        }
        public ReamerParametriViewModel(EditWorkViewModel parent, Alesatura alesatura)
            : base(parent, alesatura, "Reamer")
        {
            _alesatura = alesatura;

            EditWorkParent = parent;
        }
        public SpianaturaParametriViewModel(EditWorkViewModel parent, Model.ConversationalStructure.Lavorazioni.Fresatura.Spianatura spianatura)
            : base("Face Milling Parameter", parent)
        {
            _spianatura = spianatura;

            EditWorkParent = parent;
        }
        public BarenaturaParametriViewModel(EditWorkViewModel parent, Barenatura barenatura)
            : base(parent, barenatura, "Boring")
        {
            _barenatura = barenatura;

            EditWorkParent = parent;
        }
예제 #5
0
        public LamaturaParametriViewModel(EditWorkViewModel parent, Lamatura lamatura)
            : base(parent, lamatura, "Counterbore")
        {
            _lamatura = lamatura;

            EditWorkParent = parent;
        }
예제 #6
0
        public ForaturaSempliceParametriViewModel(EditWorkViewModel parent, ForaturaSemplice foraturaSemplice)
            : base(parent, foraturaSemplice, "Drilling Parameter")
        {
            _foraturaSemplice = foraturaSemplice;

            EditWorkParent = parent;
        }
예제 #7
0
        public MaschiaturaParametriViewModel(EditWorkViewModel parent, Maschiatura maschiatura)
            : base(parent, maschiatura, "Tapping")
        {
            _maschiatura = maschiatura;

            EditWorkParent = parent;
        }
        public CommonDrillParametriViewModel(EditWorkViewModel parent, DrillBaseClass drillBaseClass, string label)
            : base(label, parent)
        {
            _drillBaseClass = drillBaseClass;

            EditWorkParent = parent;
        }
        public EditStageTreeViewItem(string label, EditWorkViewModel viewModelEditWorkParent)
            : base(null, false)
        {
            EditWorkParent = viewModelEditWorkParent;

            Label = label;

            OnItemSelected += EditStageTreeViewItem_OnItemSelected;
        }
예제 #10
0
        public FresaturaLatoParametriViewModel(EditWorkViewModel parent, Model.ConversationalStructure.Lavorazioni.Fresatura.FresaturaLato fresaturaLato)
            : base("Parameter", parent)
        {
            _fresaturaLato = fresaturaLato;

            EditWorkParent = parent;

            RotoTraslateWorkViewModel = new RotoTraslateWorkViewModel(this._fresaturaLato, this);
        }
예제 #11
0
        public ForaturaCommonOperazioniViewModel(DrillBaseClass drillBaseClass, EditWorkViewModel parent)
            : base("Operation", parent)
        {
            _drillBaseClass = drillBaseClass;

            foreach (var operazione in _drillBaseClass.Operazioni)
            {
                OperationList.Add(GetViewModel(operazione, drillBaseClass, parent));
            }
        }
예제 #12
0
        public OperazioneViewModel(Operazione operazione, EditWorkViewModel parent)
            : base(operazione.Descrizione, parent)
        {
            Operazione = operazione;

            if (operazione.FirstStart)
            {
                AutoToolFind();
                operazione.FirstStart = false;
            }
            else
            {
                LoadCompatibleTools();
            }
        }
        public ScanalaturaLineaParametriViewModel(EditWorkViewModel parent, Model.ConversationalStructure.Lavorazioni.Fresatura.ScanalaturaLinea scanalaturaLinea)
            : base("Parameter", parent)
        {
            /*
             * fare classe base per gestire la rotazione e array..
             */
            _scanalaturaLinea = scanalaturaLinea;

            EditWorkParent = parent;


            RotoTraslateWorkViewModel = new RotoTraslateWorkViewModel(_scanalaturaLinea, this);

            Children.Add(RotoTraslateWorkViewModel);
            //RotoTraslateWorkViewModel = new RotoTraslateWorkViewModel(this._scanalaturaLinea, this);
        }
예제 #14
0
        public async Task <IActionResult> EditWork(EditWorkViewModel workViewModel)
        {
            var userId     = User.FindFirstValue(ClaimTypes.NameIdentifier);
            var specialist = await _specialistService.FindAsync(userId);

            if (ModelState.IsValid)
            {
                var work = await _specialistService.EditWork(workViewModel.Id, workViewModel.Description);

                if (work != null)
                {
                    TempData["Status"] = "Changes saved successfully";
                    return(RedirectToAction("Works"));
                }
            }
            return(View(workViewModel));
        }
예제 #15
0
        public async Task <IActionResult> EditWork(int id)
        {
            var userId     = User.FindFirstValue(ClaimTypes.NameIdentifier);
            var specialist = await _specialistService.FindAsync(userId);

            var work = await _specialistService.FindWork(id);

            if (work.SpecialistId != specialist.Id)
            {
                return(RedirectToAction("Works"));
            }

            var model = new EditWorkViewModel {
                Id = work.Id, ImagePath = work.ImagePath, Description = work.Description
            };

            return(View(model));
        }
        public ProfileEditorViewModel(RawProfile profile, EditWorkViewModel workViewModel, AxisSystem axisSystem)
            : base("Input Profile", workViewModel)
        {
            _rawProfile = profile;

            CurrentAxisSystem = axisSystem;

            MoveListViewModels = new ObservableCollection <RawItemViewModel>();

            DictionaryKey = CreateKeyboardShortcuts(CurrentAxisSystem);
            var moveList = profile.GetMoveList();

            foreach (var rawEntity2D in moveList)
            {
                //MoveListViewModels.Add(RawItemViewModel.GetViewModel(rawEntity2D, axisSystem));
                MoveListViewModels.Add(GetViewModel(rawEntity2D));
            }

            SelectedMoveViewModel = MoveListViewModels.LastOrDefault();

            UpdatePreview();

            UpdateMoveListOrientation();
        }
예제 #17
0
 public SpianaturaOperazioni(Model.ConversationalStructure.Lavorazioni.Fresatura.Spianatura spianatura, EditWorkViewModel parent)
     : base("Operation", parent)
 {
     _spianatura = spianatura;
 }
예제 #18
0
 public CommonMillOperationViewModel(IMillWorkable millWorkable, EditWorkViewModel parent)
     : base("Operation", parent)
 {
     _millWorkable = millWorkable;
 }
예제 #19
0
 public FresaturaScanalaturaChiusaOperazioniViewModel(FresaturaScanalaturaChiusa fresaturaScanalaturaChiusa, EditWorkViewModel parent)
     : base("Operation", parent)
 {
     _fresaturaScanalaturaChiusa = fresaturaScanalaturaChiusa;
 }
 public TextEngravingParametriViewModel(TextEngravingModel textEngravingModel, EditWorkViewModel treeItemParent)
     : base("Parameter", treeItemParent)
 {
     _textEngravingModel = textEngravingModel;
 }
        public FresaturaFilettaturaParametriViewModel(FresaturaFilettatura fresaturaFilettatura, EditWorkViewModel treeItemParent)
            : base("Parameter", treeItemParent)
        {
            _fresaturaFilettatura = fresaturaFilettatura;

            //RotoTraslateWorkViewModel = new RotoTraslateWorkViewModel(this._fresaturaCava, this);
        }
예제 #22
0
 public CentrinoOperazioneViewModel(ICentrinoAble centrinoAble, EditWorkViewModel editWorkViewModel)
 {
     _editWorkParent = editWorkViewModel;
     _centrinoAble   = centrinoAble;
 }
예제 #23
0
 public LamaturaOperazioneViewModel(ILamaturaAble svasaturaAble, EditWorkViewModel editWorkViewModel)
 {
     _editWorkParent = editWorkViewModel;
     _lamaturaAble   = svasaturaAble;
 }
예제 #24
0
 public MaschiaturaOperazioneViewModel(IMaschiaturaAble maschiaturaAble, EditWorkViewModel editWorkViewModel)
 {
     _editWorkParent  = editWorkViewModel;
     _maschiaturaAble = maschiaturaAble;
 }
예제 #25
0
 public SvasaturaOperazioneViewModel(ISvasaturaAble svasaturaAble, EditWorkViewModel editWorkViewModel)
 {
     _editWorkParent = editWorkViewModel;
     _centrinoAble   = svasaturaAble;
 }
예제 #26
0
 public FresaturaCavaParametriViewModel(FresaturaCava fresaturaCava, EditWorkViewModel treeItemParent)
     : base("Parameter", treeItemParent)
 {
     _fresaturaCava = fresaturaCava;
 }
예제 #27
0
 public ForaturaPuntaOperazioneViewModel(IForaturaAble foratura, EditWorkViewModel editWorkViewModel)
 {
     _editWorkParent = editWorkViewModel;
     _foratura       = foratura;
 }
예제 #28
0
 public BarenoOperazioneViewModel(IBarenoAble barenoAble, EditWorkViewModel editWorkViewModel)
 {
     _editWorkParent = editWorkViewModel;
     _barenoAble     = barenoAble;
 }
 public SfacciaturaParametriViewModel(TornituraSfacciatura sfacciatura, EditWorkViewModel treeItemParent)
     : base("Parameter", treeItemParent)
 {
     _sfacciatura = sfacciatura;
 }
예제 #30
0
 public ScanalaturaLineaOperazioniViewModel(Model.ConversationalStructure.Lavorazioni.Fresatura.ScanalaturaLinea scanalaturaLinea, EditWorkViewModel parent)
     : base(scanalaturaLinea, parent)
 {
     _scanalaturaLinea = scanalaturaLinea;
 }