public MultipleVoucherRedeemStatus(RedeemMultipleTickets objR, Action doWork)
 {
     InitializeComponent();
     _redeemMultipleTickets = objR;
     _DoWork         = doWork;
     _dAction        = new WaitCallback(this.DoAction);
     this.ResizeMode = System.Windows.ResizeMode.NoResize;
 }
 public MultipleVoucherRedeemStatus(RedeemMultipleTickets objR,Action doWork)
 {
     InitializeComponent();
     _redeemMultipleTickets = objR;
     _DoWork = doWork;
     _dAction = new WaitCallback(this.DoAction);
     this.ResizeMode = System.Windows.ResizeMode.NoResize;
 }
 private void Dispose(bool disposing)
 {
     if (!disposed)
     {
         if (disposing)
         {
             _redeemMultipleTickets = null;
         }
         disposed = true;
     }
 }
        private void Dispose(bool disposing)
        {
            if (!disposed)
            {
                if (disposing)
                {
                    _redeemMultipleTickets = null;

                }
                disposed = true;
            }
        }
コード例 #5
0
        void CTickets_Loaded(object sender, RoutedEventArgs e)
        {
            //if (Settings.CAGE_ENABLED)                                    //-S001
            if (Settings.CAGE_ENABLED || !(IsTitoEnabled()) )       //+S001
            {
                chkPrint.Visibility = Visibility.Collapsed;
                chkRedeem.Visibility = Visibility.Collapsed;
                chkVoid.Visibility = Visibility.Collapsed;
                chkMultipleVoucherRedeem.Visibility = Visibility.Collapsed;
            }
            else
            {
                if (!SecurityHelper.HasAccess("BMC.Presentation.CPrintTicket"))
                    chkPrint.Visibility = Visibility.Collapsed;

                if (!SecurityHelper.HasAccess("BMC.Presentation.CRedeemTicket"))
                {
                    chkRedeem.Visibility = Visibility.Collapsed;
                    if (chkPrint.Visibility != Visibility.Collapsed)
                        chkPrint.IsChecked = true;
                }
                else
                    chkRedeem.IsChecked = true;

                if ((!SecurityHelper.HasAccess("BMC.Presentation.MultipleVoucher")) || !Settings.IsMultipleVoucherRedemptionEnabled)
                {
                    chkMultipleVoucherRedeem.Visibility = Visibility.Collapsed;
                }
                else
                {
                    redeemMultipleTickets = new RedeemMultipleTickets();
                    chkMultipleVoucherRedeem.IsChecked = true;
                    
                }
            }

            if (!SecurityHelper.HasAccess("CashdeskOperator.MainScreen.cs.AttendantPay"))
            {
                chkAttendantPays.Visibility = Visibility.Collapsed;
                if (chkPrint.Visibility != Visibility.Collapsed)
                    chkPrint.IsChecked = true;             
            }
            else if ((chkPrint.Visibility == Visibility.Collapsed) && (chkRedeem.Visibility == Visibility.Collapsed))
                chkAttendantPays.IsChecked = true;
            

            if ((!SecurityHelper.HasAccess("CashdeskOperator.MainScreen.cs.ManualAttendantPay")) || (!Settings.HandpayManual))
            {
                chkManualAttendantPays.Visibility = Visibility.Collapsed;
                if (chkPrint.Visibility != Visibility.Collapsed)
                    chkPrint.IsChecked = true;
            }
            if (!SecurityHelper.HasAccess("CashdeskOperator.MainScreen.cs.CVoidTicket") || !Settings.VoidVouchers)
            {
                chkVoid.Visibility = Visibility.Collapsed;
                if (chkVoid.Visibility != Visibility.Collapsed)
                    chkVoid.IsChecked = true;
            }

            if (chkRedeem.Visibility != Visibility.Collapsed)
                chkRedeem.IsChecked = true;
            else if (chkPrint.Visibility != Visibility.Collapsed)
                chkPrint.IsChecked = true;             
            else if (chkVoid.Visibility != Visibility.Collapsed)
                chkVoid.IsChecked = true;
            else if (chkAttendantPays.Visibility != Visibility.Collapsed)
                chkAttendantPays.IsChecked = true;
            else if (chkManualAttendantPays.Visibility != Visibility.Collapsed)
                chkManualAttendantPays.IsChecked = true;
           
            //if (Settings.CAGE_ENABLED)
            //{
            //    chkPrint.Visibility = Visibility.Collapsed;
            //    chkRedeem.Visibility = Visibility.Collapsed;

            //}
            
            //if (!SecurityHelper.HasAccess("BMC.Presentation.CPrintTicket"))
            //    chkPrint.Visibility = Visibility.Collapsed;


            //if (!SecurityHelper.HasAccess("CashdeskOperator.MainScreen.cs.AttendantPay"))
            //{
            //    chkAttendantPays.Visibility = Visibility.Collapsed;
            //    if (chkPrint.Visibility != Visibility.Collapsed)
            //        chkPrint.IsChecked = true;
            //}
            //else
            //    chkRedeem.IsChecked = true;

            //if (!SecurityHelper.HasAccess("CashdeskOperator.MainScreen.cs.ManualAttendantPay"))
            //{
            //  chkManualAttendantPays.Visibility = Visibility.Collapsed;
            //    if (chkPrint.Visibility != Visibility.Collapsed)
            //        chkPrint.IsChecked = true;
            //}

            //if (!SecurityHelper.HasAccess("BMC.Presentation.CRedeemTicket"))
            //{
            //    chkRedeem.Visibility = Visibility.Collapsed;
            //    if (chkPrint.Visibility != Visibility.Collapsed)
            //        chkPrint.IsChecked = true;
            //}
            //else
            //    chkAttendantPays.IsChecked = true;

            ////if (chkPrint.Visibility == Visibility.Collapsed && chkRedeem.Visibility == Visibility.Collapsed)
            ////    pnlTicketContent.Visibility = Visibility.Hidden;

            //if (Settings.Not_Issue_Ticket)
            //    chkPrint.IsEnabled = false;      
        }