Exemplo n.º 1
0
        // delegate void DoPaymentsOperDelegate(int PaymentsCount, Check Chk);

        static private void DoPaymentsOper(int PaymentsCount, Check Chk)
        {
            Utils.ToCardLog("DoPaymentsOper TenderType = " + PaymentsCount.ToString());
            if (PaymentsCount == 1)
            {
                FCC.SetBill();
            }
            else if (PaymentsCount == 2)
            {
                /*
                 * if (iniFile.InPasEnabled)
                 * {
                 *  DualConnector.DualConnectorMain.Sale();
                 * }
                 * */
                //   else if (iniFile.Arcus2Enabled)
                if (CreditCardAlohaIntegration.CreditCardConnectorEnabled)
                {
                    string err = "";

                    CreditCardAlohaIntegration.RunOper(Chk);
                    //DualConnector.DualConnectorMain.Sale();
                }
            }
            else if (PaymentsCount == 4)
            {
                AlohaTSClass.LogOut();
                RemoteCloseCheck.AddRemoteChkToQuere(Chk.AlohaCheckNum, 30, Chk.Waiter, Chk.Summ);
            }
            GC.Collect();
            Utils.ToCardLog("Exit from DoPaymentsOper TenderType = " + PaymentsCount.ToString());
            GC.Collect();
        }
 void ctrlDigitalKeyBoard1_OnOk(object sender, double Value)
 {
     ToShtrih.CashIncome(Convert.ToDecimal(Value));
     FCC.WriteIncomeInfoToFccMoneyLog(Convert.ToDecimal(Value));
     this.Close();
 }
Exemplo n.º 3
0
        public void Custom(string Name)
        {
            try
            {
                Utils.ToLog("Custom " + Name);
                if (Name == "DeleteItemsAndCloseCheck")
                {
                    Utils.ToCardLog("DeleteItemsAndCloseCheck");
                    AlohaEventVoids.DeleteItemsAndCloseCheck();
                }
                if (Name == "PrintCheck")
                //  else if (Name == "PlasticCopySlip")
                {
                    if (iniFile.PrintPrecheckOnFR)
                    {
                        AlohaEventVoids.PrintCurentPrecheckOnFR();
                    }
                    else
                    {
                        AlohaTSClass.PrintCurentPredcheck();
                    }
                    return;
                    //AlohaEventVoids.CloseCheck();
                }
                if (Name == "CloseCheck")
                {
                    AlohaEventVoids.CloseCheck();
                }
                if (Name == "XReport")
                {
                    Utils.ToCardLog("Custom XReport");
                    AlohaEventVoids.XReport();
                }
                if (Name == "XReportHamster")
                {
                    AlohaEventVoids.XReportHamster();
                }
                if (Name == "ZReport")
                {
                    AlohaEventVoids.ZReport();
                }
                if (Name == "OrderItems")
                {
                    AlohaEventVoids.OrderItems();
                }
                if (Name == "ApplyPayment5000")
                {
                    AlohaEventVoids.ApplyPayment(5000);
                }
                if (Name == "ShowReportSale")
                {
                    AlohaEventVoids.ShowReportSale();
                }
                if (Name == "ShowTotalSumm")
                {
                    AlohaEventVoids.ShowTotalSumm();
                    //AlohaTSClass.GetSelectedItems();
                    //OrderDivider.OrderItems();
                    //OrderDivider.HideWindow();
                }
                if (Name == "OrderItemsWithDivide")
                {
                    OrderDivider.OrderItems(false);
                }
                if (Name == "OrderAllItemsWithDivide")
                {
                    OrderDivider.OrderItems(true);
                }


                if (Name == "AddWaiterToCheck")
                {
                    AlohaEventVoids.AddWaiterToCheck();
                }

                if (Name == "Plastik")
                {
                    if (iniFile.ArcusEnabled)
                    {
                        ArcusAlohaIntegrator.XReport();
                    }
                    else if (iniFile.TRPOSXEnables)
                    {
                        TrPosXAlohaIntegrator.FoolReport();
                    }
                }
                if (Name == "PlastikXReport")
                {
                    if (iniFile.ArcusEnabled)
                    {
                        ArcusAlohaIntegrator.PrintShortReport();
                        //AlohaEventVoids.TestPrintWithPause();
                    }
                    else if (iniFile.TRPOSXEnables)
                    {
                        TrPosXAlohaIntegrator.XReport();
                    }
                    else
                    {
                        AlohaTSClass.ShowMessage("Нет подключенных безналичных терминалов. TRPOSXEnables=0 и ArcusEnabled=0");
                    }
                }
                else if (Name == "PlasticSverka")
                {
                    if (iniFile.ArcusEnabled)
                    {
                        ArcusAlohaIntegrator.SverkaWithQ();
                    }
                    else
                    {
                        TrPosXAlohaIntegrator.SverkaWithQ();
                    }
                }
                else if (Name == "PlasticCopySlip")
                {
                    if (iniFile.ArcusEnabled)
                    {
                        ArcusAlohaIntegrator.GetSipCopy();
                    }
                    else if (iniFile.TRPOSXEnables)
                    {
                        TrPosXAlohaIntegrator.GetSlipCopy();
                    }
                    else
                    {
                        AlohaTSClass.ShowMessage("Нет подключенных безналичных терминалов. TRPOSXEnables=0 и ArcusEnabled=0 ");
                    }
                }

                else if (Name == "ShowStopList")
                {
                    //  AlohaEventVoids.ShowStopListReason();
                    AlohaEventVoids.ShowStopList();
                }
                else if (Name == "ShowStopListReason")
                {
                    AlohaEventVoids.ShowStopListReason();
                }
                else if (Name == "Degustations")
                {
                    AlohaEventVoids.Degustations();
                }
                if (Name == "Payment")
                {
                    DisplayBoardClass.ApplyPaymentEvent();
                }
                if (Name == "ShowfrmCard")
                {
                    AlohaEventVoids.ShowfrmCard();
                }
                if (Name == "ShowfrmModifItem")
                {
                    AlohaEventVoids.ShowfrmModifItem();
                }
                if (Name.Length > 5)
                {
                    if (Name.Substring(0, 5) == "Scale")
                    {
                        AlohaEventVoids.AddScaleDish2(Name);
                    }
                }
                if (Name == "VIP")
                {
                    AlohaEventVoids.SetVip();
                }
                if (Name == "FCCShowAdmin")
                {
                    FCC.ShowAdmin();
                }
                if (Name == "FCCSetBill")
                {
                    FCC.SetBill();
                }
                if (Name == "FCCSetBillWithHands")
                {
                    //FCC.SetBillWithHands();
                }
                if (Name == "FCCShowCassir")
                {
                    FCC.ShowCassirFrm();
                }
                if (Name == "FCCInspectSmallChange")
                {
                    FCC.InpectSmallChange(true);
                }


                if (Name == "ShowCashIncome")
                {
                    AlohaEventVoids.ShowFrmCashIn();
                }
                if (Name == "FCCShowRazmen")
                {
                    FCC.ShowRazmen();
                    // DualConnector.DualConnectorMain.InFuncsfrm();
                }

                if (Name == "CloseByWaiter")
                {
                    AlohaEventVoids.CloseByWaiter();
                }
                if (Name == "CloseByWaiterCard")
                {
                    AlohaEventVoids.CloseByWaiter(2);
                }
                if (Name == "CloseByWaiterGlory")
                {
                    if (!AlohaTSClass.IsAlohaTS() && !iniFile.FCCEnable)
                    {
                        Utils.ToLog("CloseByWaiterGlory && (!AlohaTSClass.IsAlohaTS() && !iniFile.FCCEnable)");
                        AlohaEventVoids.CloseCheck();
                    }
                    else
                    {
                        AlohaEventVoids.CloseByWaiter(1);
                    }
                }

                /*
                 *
                 * if (Name == "InPasShortReport")
                 * {
                 *  DualConnector.DualConnectorMain.ShortReport();
                 * }
                 * if (Name == "InPasFullReport")
                 * {
                 *  DualConnector.DualConnectorMain.LongReport();
                 * }
                 * if (Name == "InPasSverka")
                 * {
                 *  DualConnector.DualConnectorMain.Sverka();
                 * }
                 *
                 * if (Name == "InPasLastChk")
                 * {
                 *  DualConnector.DualConnectorMain.GetCopyLastSlip();
                 * }
                 *
                 * if (Name == "InPasAnyChk")
                 * {
                 *  DualConnector.DualConnectorMain.GetCopySlip();
                 * }
                 * */
                if ((Name == "InPasFuncsfrm") || ((Name == "PlasticFuncsfrm")))
                {
                    /*
                     * if (iniFile.InPasEnabled)
                     * {
                     *  DualConnector.DualConnectorMain.InPasFuncsfrm();
                     * }
                     * else
                     * */
                    {
                        CreditCardAlohaIntegration.ShowFuncsfrm();
                    }
                }

                if (Name == "WestReport0")
                {
                    West.WestMain.ShowSaleReport(0);
                }
                if (Name == "WestReport1")
                {
                    West.WestMain.ShowSaleReport(1);
                }
                if (Name == "WestPager")
                {
                    West.WestMain.mShowPagerDialog();
                }
                if (Name == "BonusCardReport")
                {
                    Loyalty.LoyaltyBasik.PrintLongSlipReport();
                }

                if (Name == "EGAISScan")
                {
                    EGAIS.EGAISCodeReader.Read();
                }
                if (Name == "ReprintCheck")
                {
                    FRSClientApp.FRSClient.PrintFCheckShowWnd();
                }
                if (Name == "FayRetailCard")
                {
                    FayRetail.FayRetailMain.ShowWndApplyCardWithCurentCheck();
                }
                if (Name == "PBFirstRequest")
                {
                    MB.PB.SendCurentChk();
                }
            }
            catch (Exception e)
            {
                Utils.ToCardLog("[Error] Custom " + Name + ", Mess: " + e.Message);
            }

            /*
             * else if (Name == "PlastikVozvrat")
             * {
             * TrPosXClass.Void(100) ;
             * }
             * */
        }