| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143 | using System;using System.Collections.Generic;using System.Linq;using System.Text;using System.Threading.Tasks;using System.Windows;using FurnaceUI.Models;namespace FurnaceUI.Views.Operations{    public class BoatElevatorParametersViewModel : FurnaceUIViewModelBase    {        public int point1Count { get; set; }        public int point2Count { get; set; }        public int point3Count { get; set; }        public int point4Count { get; set; }        public int point5Count { get; set; }        public int point6Count { get; set; }        private bool _RecipeControl1;        public bool RecipeControl1        {            get => _RecipeControl1;            set            {                _RecipeControl1 = value;                NotifyOfPropertyChange("RecipeControl1");            }        }        private bool _RecipeControl2;        public bool RecipeControl2        {            get => _RecipeControl2;            set            {                _RecipeControl2 = value;                NotifyOfPropertyChange("RecipeControl2");            }        }        private bool _RecipeControl3;        public bool RecipeControl3        {            get => _RecipeControl3;            set            {                _RecipeControl3 = value;                NotifyOfPropertyChange("RecipeControl3");            }        }        private bool _RecipeControl4;        public bool RecipeControl4        {            get => _RecipeControl4;            set            {                _RecipeControl4 = value;                NotifyOfPropertyChange("RecipeControl4");            }        }        private bool _RecipeControl5;        public bool RecipeControl5        {            get => _RecipeControl5;            set            {                _RecipeControl5 = value;                NotifyOfPropertyChange("RecipeControl5");            }        }        private bool _RecipeControl6;        public bool RecipeControl6        {            get => _RecipeControl6;            set            {                _RecipeControl6 = value;                NotifyOfPropertyChange("RecipeControl6");            }        }        public void RecipeControlCheck(string value)        {            switch (value)            {                case "1":                    point1Count++;                    if (point1Count % 2 == 0)                        RecipeControl1 = false;                    else                        RecipeControl1 = true;                    break;                case "2":                    point2Count++;                    if (point2Count % 2 == 0)                        RecipeControl2 = false;                    else                        RecipeControl2 = true;                    break;                case "3":                    point3Count++;                    if (point3Count % 2 == 0)                        RecipeControl3 = false;                    else                        RecipeControl3 = true;                    break;                case "4":                    point4Count++;                    if (point4Count % 2 == 0)                        RecipeControl4 = false;                    else                        RecipeControl4 = true;                    break;                case "5":                    point5Count++;                    if (point5Count % 2 == 0)                        RecipeControl5 = false;                    else                        RecipeControl5 = true;                    break;                case "6":                    point6Count++;                    if (point6Count % 2 == 0)                        RecipeControl6 = false;                    else                        RecipeControl6 = true;                    break;                default:                    break;            }        }        public void Close()        {            ((Window)GetView())?.Close();        }    }}
 |