Exemplo n.º 1
0
        private void btnEmployeeAccount_Click(object sender, RoutedEventArgs e)
        {
            AccessWindow window = new AccessWindow(Status.EMPLOYEE);

            window.Show();
            Close();
        }
Exemplo n.º 2
0
        private void btnCancel_Click(object sender, RoutedEventArgs e)
        {
            if (window == PreviousWindow.ACCESS)
            {
                AccessWindow accessWindow = new AccessWindow(status);
                accessWindow.Show();
                Close();
            }
            else if (window == PreviousWindow.LOGIN || window == PreviousWindow.MENU)
            {
                MessageBoxResult result =
                    MessageBox.Show(ConfigurationManager.AppSettings["btnCancelMessage"],
                                    "",
                                    MessageBoxButton.YesNo);

                if (result == MessageBoxResult.Yes && window == PreviousWindow.LOGIN)
                {
                    LoginWindow loginWindow = new LoginWindow();
                    loginWindow.Show();
                    this.Close();
                }
                else if (result == MessageBoxResult.Yes && window == PreviousWindow.MENU)
                {
                    MenuWindow menuWindow = new MenuWindow(null, Status.NO_ACCOUNT);
                    menuWindow.Show();
                    Close();
                }
            }
        }
Exemplo n.º 3
0
        private void btnCustomerAccount_Click(object sender, RoutedEventArgs e)
        {
            AccessWindow window = new AccessWindow(Status.CUSTOMER);

            window.Show();
            Close();
        }