protected override void RemoveEmployeeMethod(IEmployeeVM parameter) { // base.RemoveEmployeeMethod(parameter); if (!RemoveEmployeeCanMethod(parameter)) { return; } EmployeeVM empl = (EmployeeVM)parameter; model.RemoveEmployee(empl.Dto); }
protected override void AddEmployeeMethod(IEmployeeVM parameter) { // base.AddEmployeeMethod(parameter); if (!AddEmployeeCanMethod(parameter)) { return; } EmployeeVM empl = (EmployeeVM)parameter; model.AddEmployee(empl.Copy()); ModeExitMethod(ViewModeEnum.Adding); }
protected override void SaveEditEmployeeMethod(IEmployeeVM parameter) { // base.SaveEditEmployeeMethod(parameter); if (!SaveEditEmployeeCanMethod(parameter)) { return; } EmployeeVM empl = (EmployeeVM)parameter; model.ChangeEmployee(empl.Dto, empl.Copy()); ModeExitMethod(ViewModeEnum.Editing); }