public AdministratorChangeCashDispenserStatePanel(
            AdministratorChangeCashDispenserStatePanelVM
            administratorChangeCashDispenserStatePanelVM)
        {
            InitializeComponent();

            // Set login panel information
            this.loginPanel = administratorChangeCashDispenserStatePanelVM.loginPanel;

            // Set administrator panel information
            this.administratorPanel =
                administratorChangeCashDispenserStatePanelVM.AdministratorPanel;

            // Set administrator cash dispenser state panel
            this.administratorCashDispenserStatePanel =
                administratorChangeCashDispenserStatePanelVM.administratorCashDispenserStatePanel;

            // Set cash dispenser state in Pln currency
            this.cashDispenserStateInPln =
                administratorChangeCashDispenserStatePanelVM
                .cashDispenserStateInPlnCurrency;

            // Show cash dispenser state
            this.CashDispenserStateValueLabel.Text =
                (String.Format("{0:0.00}", this.cashDispenserStateInPln));

            // Hide error label
            this.ErrorLabel.Visible = false;
        }
예제 #2
0
        private void CashWithdrawalStateButton_Click(object sender, EventArgs e)
        {
            // Redirect to administrator cash dispenser state panel
            AdministratorCashDispenserStatePanelVM administratorCashDispenserStatePanelVM =
                new AdministratorCashDispenserStatePanelVM
            {
                loginPanel         = this.loginPanel,
                administratorPanel = this
            };

            AdministratorCashDispenserStatePanel administratorCashDispenserStatePanel =
                new AdministratorCashDispenserStatePanel(
                    administratorCashDispenserStatePanelVM);

            administratorCashDispenserStatePanel.Show();
            this.Hide();
        }