public UserAccountFundSyncService()
        {
            InitializeComponent();

            try
            {
                this._LocalLogger = new Common.General(Common.General.BindLocalLogInfo());
                this._DBLogger = new Common.General(Common.General.BindDbLogInfo());

                this._ServiceName = ConfigurationSettings.AppSettings["ServiceName"];
                if (string.IsNullOrEmpty(this._ServiceName))
                {
                    this._ServiceName = "ServAccountSync";
                }
                this._ServiceName.PadRight(20, ' ').Substring(0, 20).Trim();

                this._IPreConsumeRecordBL = MasterBLLFactory.GetBLL<IPreConsumeRecordBL>(MasterBLLFactory.PreConsumeRecord);
                this._IConsumeRecordBL = MasterBLLFactory.GetBLL<IConsumeRecordBL>(MasterBLLFactory.ConsumeRecord);
                this._ICodeMasterBL = BLL.Factory.SysMaster.MasterBLLFactory.GetBLL<ICodeMasterBL>(BLL.Factory.SysMaster.MasterBLLFactory.CodeMaster_cmt);
                this._IConsumeMachineBL = MasterBLLFactory.GetBLL<IConsumeMachineBL>(MasterBLLFactory.ConsumeMachine);
                this._ICardUserAccountBL = MasterBLLFactory.GetBLL<ICardUserAccountBL>(MasterBLLFactory.CardUserAccount);

                this._tmrMain = new System.Timers.Timer();
                this._tmrMain.Interval = 60000;
                this._tmrMain.Elapsed += new System.Timers.ElapsedEventHandler(_tmrMain_Elapsed);

                this._LocalLogger.WriteLog("服务初始化完毕。 " + DateTime.Now.ToString(), string.Empty, SystemLog.SystemLog.LogType.Trace);
            }
            catch (Exception ex)
            {
                this._LocalLogger.WriteLog("服务初始化失败。" + ex.Message + " " + DateTime.Now.ToString(), string.Empty, SystemLog.SystemLog.LogType.Error);
            }
        }
Пример #2
0
        public override void Show()
        {
            if (_iucpBL == null)
            {
                _iucpBL = MasterBLLFactory.GetBLL<IUserCardPairBL>(MasterBLLFactory.UserCardPair);
            }
            if (_icuadBL == null)
            {
                _icuadBL = MasterBLLFactory.GetBLL<ICardUserAccountDetailBL>(MasterBLLFactory.CardUserAccountDetail);
            }
            if (_icuaBL == null)
            {
                _icuaBL = MasterBLLFactory.GetBLL<ICardUserAccountBL>(MasterBLLFactory.CardUserAccount);
            }
            if (_ipcrBL == null)
            {
                _ipcrBL = MasterBLLFactory.GetBLL<IPreConsumeRecordBL>(MasterBLLFactory.PreConsumeRecord);
            }
            if (_IConsumeRecordBL == null)
            {
                _IConsumeRecordBL = MasterBLLFactory.GetBLL<IConsumeRecordBL>(MasterBLLFactory.ConsumeRecord);
            }

            ReadCard();
        }
Пример #3
0
        public frmChangePreCostStatus()
        {
            InitializeComponent();

            this._IPreConsumeRecordBL = MasterBLLFactory.GetBLL<IPreConsumeRecordBL>(MasterBLLFactory.PreConsumeRecord);
            this._ICardUserMasterBL = MasterBLLFactory.GetBLL<ICardUserMasterBL>(MasterBLLFactory.CardUserMaster);
            this._IUserCardPairBL = MasterBLLFactory.GetBLL<IUserCardPairBL>(MasterBLLFactory.UserCardPair);
            this._IGeneralBL = GeneralBLLFactory.GetBLL<IGeneralBL>(GeneralBLLFactory.General);
        }
Пример #4
0
        public frmRefundOfflineSingle()
        {
            InitializeComponent();

            this._ICardUserAccountBL = MasterBLLFactory.GetBLL<ICardUserAccountBL>(MasterBLLFactory.CardUserAccount);
            this._IUserCardPairBL = MasterBLLFactory.GetBLL<IUserCardPairBL>(MasterBLLFactory.UserCardPair);
            this._IRechargeRecordBL = MasterBLLFactory.GetBLL<IRechargeRecordBL>(MasterBLLFactory.RechargeRecord);
            this._IPreRechargeRecordBL = MasterBLLFactory.GetBLL<IPreRechargeRecordBL>(MasterBLLFactory.PreRechargeRecord);
            this._IPreConsumeRecordBL = MasterBLLFactory.GetBLL<IPreConsumeRecordBL>(MasterBLLFactory.PreConsumeRecord);
        }
Пример #5
0
        public frmRefundCash()
            : base()
        {
            InitializeComponent();

            this._ICardUserAccountBL = MasterBLLFactory.GetBLL<ICardUserAccountBL>(MasterBLLFactory.CardUserAccount);
            this._IUserCardPairBL = MasterBLLFactory.GetBLL<IUserCardPairBL>(MasterBLLFactory.UserCardPair);
            this._ISystemAccountDetailBL = MasterBLLFactory.GetBLL<ISystemAccountDetailBL>(MasterBLLFactory.SystemAccountDetail);
            this._IPreConsumeRecordBL = MasterBLLFactory.GetBLL<IPreConsumeRecordBL>(MasterBLLFactory.PreConsumeRecord);
            this._IRechargeRecordBL = MasterBLLFactory.GetBLL<IRechargeRecordBL>(MasterBLLFactory.RechargeRecord);
        }
Пример #6
0
        public frmCardReturn()
        {
            InitializeComponent();

            this._ListQueryStuInfo = new List<CardUserMaster_cus_Info>();

            this._IGeneralBL = GeneralBLLFactory.GetBLL<IGeneralBL>(GeneralBLLFactory.General);

            this._ICardUserMasterBL = MasterBLLFactory.GetBLL<ICardUserMasterBL>(MasterBLLFactory.CardUserMaster);
            this._IUserCardPairBL = MasterBLLFactory.GetBLL<IUserCardPairBL>(MasterBLLFactory.UserCardPair);
            this._ICardUserAccountBL = MasterBLLFactory.GetBLL<ICardUserAccountBL>(MasterBLLFactory.CardUserAccount);
            this._IPreConsumeRecordBL = MasterBLLFactory.GetBLL<IPreConsumeRecordBL>(MasterBLLFactory.PreConsumeRecord);
        }
Пример #7
0
        protected override void OnLoad(EventArgs e)
        {
            base.OnLoad(e);

            try
            {
                this._IPreConsumeRecordBL = MasterBLLFactory.GetBLL<IPreConsumeRecordBL>(MasterBLLFactory.PreConsumeRecord);
                if (this._UserInfo != null)
                {
                    List<PreConsumeRecord_pcs_Info> listPreCost = this._IPreConsumeRecordBL.SearchRecords(new PreConsumeRecord_pcs_Info() { pcs_cUserID = this._UserInfo.cus_cRecordID });
                    listPreCost = listPreCost.Where(x => x.pcs_lIsSettled == false
                        && x.pcs_cConsumeType != Common.DefineConstantValue.ConsumeMoneyFlowType.HedgeFund.ToString()
                        && x.pcs_cConsumeType != Common.DefineConstantValue.ConsumeMoneyFlowType.AdvanceMealCost.ToString()
                        ).ToList();
                    if (listPreCost != null && listPreCost.Count > 0)
                    {
                        List<PreCostDetailInfo> listPreCostDetail = new List<PreCostDetailInfo>();
                        foreach (PreConsumeRecord_pcs_Info preItem in listPreCost)
                        {
                            PreCostDetailInfo preDetail = new PreCostDetailInfo(preItem);
                            //2014-02-25 Add 添加定餐消费的餐类型描述
                            if (!string.IsNullOrEmpty(preItem.MealType))
                            {
                                string strMealTypeDesc = Common.DefineConstantValue.GetMealTypeDesc(preItem.MealType);
                                if (!string.IsNullOrEmpty(strMealTypeDesc))
                                {
                                    preDetail.ConsumeType += "--" + strMealTypeDesc;
                                }
                            }
                            //2014-02-25 End Add
                            preDetail.UserName = this._UserInfo.cus_cChaName;
                            listPreCostDetail.Add(preDetail);
                        }
                        listPreCostDetail = listPreCostDetail.OrderBy(x => x.ConsumeDate).ToList();
                        if (listPreCostDetail != null && listPreCostDetail.Count > 0)
                        {
                            listPreCostDetail = listPreCostDetail.OrderByDescending(x => x.ConsumeDate).ToList();
                            labPreCost.Text = Math.Round(listPreCostDetail.Sum(x => x.Cost), 2).ToString();
                        }

                        lvPreCostDetail.SetDataSource<PreCostDetailInfo>(listPreCostDetail);
                    }
                }
            }
            catch (Exception ex)
            {
                ShowErrorMessage(ex);
            }
        }
 public UserAccountFundSyncService()
 {
     try
     {
         this._ServiceName = "AFSServ";
         this._IPreConsumeRecordBL = MasterBLLFactory.GetBLL<IPreConsumeRecordBL>(MasterBLLFactory.PreConsumeRecord);
         this._IConsumeRecordBL = MasterBLLFactory.GetBLL<IConsumeRecordBL>(MasterBLLFactory.ConsumeRecord);
         this._ICodeMasterBL = BLL.Factory.SysMaster.MasterBLLFactory.GetBLL<ICodeMasterBL>(BLL.Factory.SysMaster.MasterBLLFactory.CodeMaster_cmt);
         this._IConsumeMachineBL = MasterBLLFactory.GetBLL<IConsumeMachineBL>(MasterBLLFactory.ConsumeMachine);
         this._ICardUserAccountBL = MasterBLLFactory.GetBLL<ICardUserAccountBL>(MasterBLLFactory.CardUserAccount);
     }
     catch (Exception ex)
     {
         Console.WriteLine(getCWStyle(ex.Message, SystemLog.SystemLog.LogType.Error));
         throw ex;
     }
 }
        public frmRechargeRealTimeDetail()
            : base()
        {
            InitializeComponent();

            this._ICardUserMasterBL = MasterBLLFactory.GetBLL<ICardUserMasterBL>(MasterBLLFactory.CardUserMaster);
            this._IUserCardPairBL = MasterBLLFactory.GetBLL<IUserCardPairBL>(MasterBLLFactory.UserCardPair);
            this._IRechargeRecordBL = MasterBLLFactory.GetBLL<IRechargeRecordBL>(MasterBLLFactory.RechargeRecord);
            this._IPreConsumeRecordBL = MasterBLLFactory.GetBLL<IPreConsumeRecordBL>(MasterBLLFactory.PreConsumeRecord);
            this._ICardUserAccountBL = MasterBLLFactory.GetBLL<ICardUserAccountBL>(MasterBLLFactory.CardUserAccount);
            this._ICardUserAccountDetailBL = MasterBLLFactory.GetBLL<ICardUserAccountDetailBL>(MasterBLLFactory.CardUserAccountDetail);

            this._tsBLLunch = null;
            this._tsMealLunch = null;
            this._tsBLSupper = null;
            this._tsMealSupper = null;
        }
Пример #10
0
        public override void Show()
        {
            if (this._IRechargeRecordBL == null)
            {
                this._IRechargeRecordBL = MasterBLLFactory.GetBLL<IRechargeRecordBL>(MasterBLLFactory.RechargeRecord);
            }
            if (this._IPreConsumeRecordBL == null)
            {
                this._IPreConsumeRecordBL = MasterBLLFactory.GetBLL<IPreConsumeRecordBL>(MasterBLLFactory.PreConsumeRecord);
            }
            if (this._IUserCardPairBL == null)
            {
                this._IUserCardPairBL = MasterBLLFactory.GetBLL<IUserCardPairBL>(MasterBLLFactory.UserCardPair);
            }
            if (this._IPreRechargeRecordBL == null)
            {
                this._IPreRechargeRecordBL = MasterBLLFactory.GetBLL<IPreRechargeRecordBL>(MasterBLLFactory.PreRechargeRecord);
            }

            InitReadCard();
        }
 /// <summary>
 /// 数据逻辑类初始化
 /// </summary>
 private void InitBLL()
 {
     this.m_ICodeMasterBL = sysFac.MasterBLLFactory.GetBLL<sysBL.ICodeMasterBL>(sysFac.MasterBLLFactory.CodeMaster_cmt);
     this.m_IConsumeMachineBL = MasterBLLFactory.GetBLL<IConsumeMachineBL>(MasterBLLFactory.ConsumeMachine);
     this.m_IMealBookingHistoryBL = MasterBLLFactory.GetBLL<IMealBookingHistoryBL>(MasterBLLFactory.MealBookingHistory);
     this.m_IPaymentUDGeneralSettingBL = MasterBLLFactory.GetBLL<IPaymentUDGeneralSettingBL>(MasterBLLFactory.PaymentUDGeneralSetting);
     this.m_IPaymentUDMealStateBL = MasterBLLFactory.GetBLL<IPaymentUDMealStateBL>(MasterBLLFactory.PaymentUDMealState);
     this.m_ICardUserMasterBL = MasterBLLFactory.GetBLL<ICardUserMasterBL>(MasterBLLFactory.CardUserMaster);
     this.m_IUserCardPairBL = MasterBLLFactory.GetBLL<IUserCardPairBL>(MasterBLLFactory.UserCardPair);
     this.m_ICardUserAccountBL = MasterBLLFactory.GetBLL<ICardUserAccountBL>(MasterBLLFactory.CardUserAccount);
     this.m_IRechargeRecordBL = MasterBLLFactory.GetBLL<RechargeRecordBL>(MasterBLLFactory.RechargeRecord);
     this.m_IPreConsumeRecordBL = MasterBLLFactory.GetBLL<IPreConsumeRecordBL>(MasterBLLFactory.PreConsumeRecord);
     this.m_IBlacklistChangeRecordBL = BLL.Factory.HHZX.MasterBLLFactory.GetBLL<IBlacklistChangeRecordBL>(BLL.Factory.HHZX.MasterBLLFactory.BlacklistChangeRecord);
     this.m_IPreRechargeRecordBL = MasterBLLFactory.GetBLL<IPreRechargeRecordBL>(MasterBLLFactory.PreRechargeRecord);
 }
Пример #12
0
        protected override void OnLoad(EventArgs e)
        {
            base.OnLoad(e);

            this.Cursor = Cursors.WaitCursor;
            try
            {
                this._ListDisplayInfos = new List<UserCardInfo>();
                this._ICardUserAccountBL = MasterBLLFactory.GetBLL<ICardUserAccountBL>(MasterBLLFactory.CardUserAccount);
                this._IPreConsumeRecordBL = MasterBLLFactory.GetBLL<IPreConsumeRecordBL>(MasterBLLFactory.PreConsumeRecord);
                this._IUserCardPairBL = MasterBLLFactory.GetBLL<IUserCardPairBL>(MasterBLLFactory.UserCardPair);

                List<UserCardInfo> listCheckInfo = checkReturnCardInfo(this._ListCheckedUsers);
                if (listCheckInfo != null)
                {
                    this._ListDisplayInfos.AddRange(listCheckInfo);
                }
                lvStudentList.SetDataSource(listCheckInfo);

                checkListViewRes();
            }
            catch (Exception ex)
            {
                ShowErrorMessage(ex);
            }

            this.Cursor = Cursors.Default;
        }
Пример #13
0
        public frmUserCardMatch()
            : base()
        {
            InitializeComponent();

            this._IGeneralBL = GeneralBLLFactory.GetBLL<IGeneralBL>(GeneralBLLFactory.General);
            this._ICardUserMasterBL = MasterBLLFactory.GetBLL<ICardUserMasterBL>(MasterBLLFactory.CardUserMaster);
            this._IUserCardPairBL = MasterBLLFactory.GetBLL<IUserCardPairBL>(MasterBLLFactory.UserCardPair);
            this._IConsumeCardMasterBL = MasterBLLFactory.GetBLL<IConsumeCardMasterBL>(MasterBLLFactory.ConsumeCardMaster);
            this._IRechargeRecordBL = MasterBLLFactory.GetBLL<IRechargeRecordBL>(MasterBLLFactory.RechargeRecord);
            this._ICodeMasterBL = sysFac.MasterBLLFactory.GetBLL<sysBL.ICodeMasterBL>(sysFac.MasterBLLFactory.CodeMaster_cmt);
            this._ICardUserAccountBL = MasterBLLFactory.GetBLL<ICardUserAccountBL>(MasterBLLFactory.CardUserAccount);
            this._IPreRechargeRecordBL = MasterBLLFactory.GetBLL<IPreRechargeRecordBL>(MasterBLLFactory.PreRechargeRecord);
            this._IPreConsumeRecordBL = MasterBLLFactory.GetBLL<IPreConsumeRecordBL>(MasterBLLFactory.PreConsumeRecord);

            labConnDetail.Click += new EventHandler(base.labReaderState_Click);

            this._tmrMatchCard = new Timer();
            this._tmrMatchCard.Interval = 1200;
            this._tmrMatchCard.Tick += new EventHandler(_tmrMatchCard_Tick);

            this._IsReadingNew = true;
        }