Ejemplo n.º 1
0
        private void ExecuteSaveCommand()
        {
            EmployeeUIEventArgs newEventArgs =
                new EmployeeUIEventArgs(
                    EmployeeUIRoutedEvent,
                    Id,
                    "Save",
                    new EmployeeModel()
            {
                Id         = Id,
                PersonName = Employee,
                BaseCost   = BaseCost,
                Base       = BaseCost * Number,
                LuxuryCost = LuxuryCost,
                Luxury     = LuxuryCost * Number,
                Number     = Number
            }
                    );

            RaiseEvent(newEventArgs);

            Base   = BaseCost * Number;
            Luxury = LuxuryCost * Number;

            ShowEmployeeVisibility = Visibility.Visible;
        }
Ejemplo n.º 2
0
        private void ExecuteDeleteEmployee()
        {
            EmployeeUIEventArgs newEventArgs =
                new EmployeeUIEventArgs(
                    EmployeeUIRoutedEvent,
                    Id,
                    "Delete"
                    );

            RaiseEvent(newEventArgs);
        }