예제 #1
0
        private void ProcessCashBlotter()
        {
            CLAS.CashBlotterRow drCB = (CLAS.CashBlotterRow)FM.GetCLASMng().DB.CashBlotter.Select("SecondConfirm is null")[0];
            bool   createsNewCB      = false;
            string processMessage    = "Process Cash Blotter (First Confirm)?";

            if (!drCB.IsFirstConfirmNull())
            {
                processMessage = "Process Cash Blotter (Second Confirm)?";
                createsNewCB   = true;
            }

            if (MessageBox.Show(processMessage, "Process Cash Blotter", MessageBoxButtons.YesNo, MessageBoxIcon.Question, MessageBoxDefaultButton.Button1) == DialogResult.Yes)
            {
                ActivityConfig.ACSeriesRow acsr;
                if (createsNewCB)
                {
                    acsr = FM.AtMng.acMng.DB.ACSeries.FindByACSeriesId(UIHelper.AtMng.GetSetting(atriumBE.AppIntSetting.CBSecondConfirmAcId));
                }
                else
                {
                    acsr = FM.AtMng.acMng.DB.ACSeries.FindByACSeriesId(UIHelper.AtMng.GetSetting(atriumBE.AppIntSetting.CBFirstConfirmAcId));
                }

                this.FileForm().ReadOnly = true;
                fACWizard facwr = new fACWizard(FM, acsr.ACSeriesId, atriumBE.ACEngine.RevType.CashBlotter, CurrentRow().CashBlotterID, null);
                this.FileForm().HookupWizClose(facwr);
                facwr.Show();
            }
        }
예제 #2
0
        public int ConfirmManage(int fileId)
        {
            CLAS.CashBlotterRow drCB = (CLAS.CashBlotterRow)GetCurrentRow()[0];
            int docId;

            System.Collections.Hashtable hashTable = new System.Collections.Hashtable();
            hashTable["fileid"]        = fileId;
            hashTable["cashblotterid"] = drCB.CashBlotterID;

            drCB.BeginEdit();
            FileManager fm = myA.AtMng.GetFile(fileId);

            if (drCB.IsFirstConfirmNull())
            {
                drCB.FirstConfirm = this.myA.AtMng.WorkingAsOfficer.OfficerId;
                docDB.DocumentRow drnew = this.myA.AtMng.GetTemplate().GenLetter(fm, "5119D", hashTable);
                docId = drnew.DocId;
            }
            else
            {
                drCB.SecondConfirm = this.myA.AtMng.WorkingAsOfficer.OfficerId;
                drCB.RemittedDate  = DateTime.Now;
                //this.myA.CreateRelatedActivity("020", DateTime.Now, "", drCB);
                Add(myA.FM.CurrentFile);
                docDB.DocumentRow drnew = this.myA.AtMng.GetTemplate().GenLetter(fm, "5119O", hashTable);
                docId = drnew.DocId;
            }
            drCB.EndEdit();

            return(docId);
        }