예제 #1
0
        public RepairEdit(int id)
        {
            InitializeComponent();
            // Insert code required on object creation below this point.

            _repair = _repairMapper.Find(id);
            FillExistParams(_repair);
        }
예제 #2
0
        private void FillExistParams(UnitRepair repair)
        {
            if (repair.Id > 0)
            {
                var model = repair.UnitAccount.ModelInfo;

                Inventory.Text = repair.UnitAccount.Inventory;
                Model.Text = model.ModelMaker.Name + " " + model.Name;
                Defect.Text = repair.Defect;
                RepairPlace.Text = repair.RepairPlace;
                Send.SelectedDate = repair.SendDate;
                Received.SelectedDate = repair.ReceivedDate;
                CompletedCb.IsChecked = repair.Completed;
            }
        }