コード例 #1
0
        public override void Modify(PaymentRecord record)
        {
            DbCommand command = this.Provider.GetStoredProcedure("spInsertUpdatePayment");

            this.MapParameterIn(command, "@PA_USER_LOGIN_ID", "dev");
            this.MapParametersIn(command, record, true);
            this.Execute(command);
            this.MapParametersOut(command, record);
        }
コード例 #2
0
        public void CreateAndAllocate(PaymentRecord record, String invoiceId)
        {
            DbCommand command = this.Provider.GetStoredProcedure("spInsertUpdatePayment");

            this.MapParameterIn(command, "@PA_USER_LOGIN_ID", "dev");
            this.MapParameterIn(command, "@PA_INV_ID", invoiceId);
            this.MapParametersIn(command, record, true);
            this.Execute(command);
            this.MapParametersOut(command, record);
        }
コード例 #3
0
        public override void Create(PaymentRecord record)
        {
            DbCommand command = this.Provider.GetStoredProcedure("spInsertUpdatePayment");

            this.MapParameterIn(command, "@PA_USER_LOGIN_ID", "dev");
            //this.MapParametersIn(command, record, true);
            //Checks if Payment is for Refund
            if (String.IsNullOrEmpty(record.RefundPayId))
            {
                this.MapParametersIn(command, record, true);
            }
            else
            {
                record.Recvd   = Decimal.Negate(record.Recvd);
                record.RecvdBc = Decimal.Negate(record.RecvdBc2);
                this.MapParametersIn(command, record, true);
                this.MapParameterIn(command, "@PA_PAY_TXN_TYPE", 3);
            }
            this.Execute(command);
            this.MapParametersOut(command, record);
        }
コード例 #4
0
        /// <summary>
        ///     Indicates whether the current <see cref="PaymentRecord" /> instance is equal to another <see cref="PaymentRecord" /> instance.
        /// </summary>
        /// <param name="that">
        ///     The <see cref="PaymentRecord" /> instance to be compared against this instance.
        /// </param>
        /// <returns>
        ///     True if both instances are considered equal; otherwise, false.
        /// </returns>
        public Boolean Equals(PaymentRecord that)
        {
            Boolean result = true;

            result = result && (this.Id.TrimOrNullify() == that.Id.TrimOrNullify());
            result = result && (this.Lock.TrimOrNullify() == that.Lock.TrimOrNullify());
            result = result && (this.CcardType.TrimOrNullify() == that.CcardType.TrimOrNullify());
            result = result && (this.Name.TrimOrNullify() == that.Name.TrimOrNullify());
            result = result && (this.Number.TrimOrNullify() == that.Number.TrimOrNullify());
            result = result && (this.ExpyDte == that.ExpyDte);
            result = result && (this.AppvlRef.TrimOrNullify() == that.AppvlRef.TrimOrNullify());
            result = result && (this.IssueNo.TrimOrNullify() == that.IssueNo.TrimOrNullify());
            result = result && (this.CurrType.TrimOrNullify() == that.CurrType.TrimOrNullify());
            result = result && (this.Recvd == that.Recvd);
            result = result && (this.RecvdBc == that.RecvdBc);
            result = result && (this.Date == that.Date);
            result = result && (this.Type.TrimOrNullify() == that.Type.TrimOrNullify());
            result = result && (this.CustomerAcc.TrimOrNullify() == that.CustomerAcc.TrimOrNullify());
            result = result && (this.UnusedVal == that.UnusedVal);
            result = result && (this.UnusedValBc == that.UnusedValBc);
            result = result && (this.GlCode.TrimOrNullify() == that.GlCode.TrimOrNullify());
            result = result && (this.Period.TrimOrNullify() == that.Period.TrimOrNullify());
            result = result && (this.OrderId.TrimOrNullify() == that.OrderId.TrimOrNullify());
            result = result && (this.Hidden == that.Hidden);
            result = result && (this.ChequeNo.TrimOrNullify() == that.ChequeNo.TrimOrNullify());
            result = result && (this.SortCode.TrimOrNullify() == that.SortCode.TrimOrNullify());
            result = result && (this.Status.TrimOrNullify() == that.Status.TrimOrNullify());
            result = result && (this.Notes.TrimOrNullify() == that.Notes.TrimOrNullify());
            result = result && (this.ValidDate == that.ValidDate);
            result = result && (this.CurrRateBc == that.CurrRateBc);
            result = result && (this.CurrRateBc2 == that.CurrRateBc2);
            result = result && (this.SelcoSpId.TrimOrNullify() == that.SelcoSpId.TrimOrNullify());
            result = result && (this.MepId.TrimOrNullify() == that.MepId.TrimOrNullify());
            result = result && (this.OrgId.TrimOrNullify() == that.OrgId.TrimOrNullify());
            result = result && (this.PnId.TrimOrNullify() == that.PnId.TrimOrNullify());
            result = result && (this.Ref.TrimOrNullify() == that.Ref.TrimOrNullify());
            result = result && (this.BookId.TrimOrNullify() == that.BookId.TrimOrNullify());
            result = result && (this.CardSecId.TrimOrNullify() == that.CardSecId.TrimOrNullify());
            result = result && (this.StartMonth.TrimOrNullify() == that.StartMonth.TrimOrNullify());
            result = result && (this.StartYear.TrimOrNullify() == that.StartYear.TrimOrNullify());
            result = result && (this.ExpyMonth.TrimOrNullify() == that.ExpyMonth.TrimOrNullify());
            result = result && (this.ExpyYear.TrimOrNullify() == that.ExpyYear.TrimOrNullify());
            result = result && (this.RefundPayId.TrimOrNullify() == that.RefundPayId.TrimOrNullify());
            result = result && (this.RefundPayRef.TrimOrNullify() == that.RefundPayRef.TrimOrNullify());
            result = result && (this.TxnType == that.TxnType);
            result = result && (this.BankingRef.TrimOrNullify() == that.BankingRef.TrimOrNullify());
            result = result && (this.BatId.TrimOrNullify() == that.BatId.TrimOrNullify());
            result = result && (this.BankChg == that.BankChg);
            result = result && (this.BankChgBc == that.BankChgBc);
            result = result && (this.BankChgBc2 == that.BankChgBc2);
            result = result && (this.MepCrtBatId.TrimOrNullify() == that.MepCrtBatId.TrimOrNullify());
            result = result && (this.RecvdBc2 == that.RecvdBc2);
            result = result && (this.UnusedValBc2 == that.UnusedValBc2);
            result = result && (this.CostCode.TrimOrNullify() == that.CostCode.TrimOrNullify());
            result = result && (this.Purpose == that.Purpose);
            result = result && (this.SchnId.TrimOrNullify() == that.SchnId.TrimOrNullify());
            result = result && (this.AddId.TrimOrNullify() == that.AddId.TrimOrNullify());
            result = result && (this.ReverseRes.TrimOrNullify() == that.ReverseRes.TrimOrNullify());
            result = result && (this.BankSortCode.TrimOrNullify() == that.BankSortCode.TrimOrNullify());
            result = result && (this.BankAccount.TrimOrNullify() == that.BankAccount.TrimOrNullify());
            result = result && (this.AccId.TrimOrNullify() == that.AccId.TrimOrNullify());
            result = result && (this.AccTranRet == that.AccTranRet);
            result = result && (this.ExpBatId.TrimOrNullify() == that.ExpBatId.TrimOrNullify());
            result = result && (this.Moto == that.Moto);
            result = result && (this.LtId.TrimOrNullify() == that.LtId.TrimOrNullify());
            result = result && (this.MstcId.TrimOrNullify() == that.MstcId.TrimOrNullify());
            result = result && (this.OriginalCustomerAcc.TrimOrNullify() == that.OriginalCustomerAcc.TrimOrNullify());
            result = result && (this.Token.TrimOrNullify() == that.Token.TrimOrNullify());
            result = result && (this.VoucherType.TrimOrNullify() == that.VoucherType.TrimOrNullify());
            result = result && (this.GatewayAccId.TrimOrNullify() == that.GatewayAccId.TrimOrNullify());
            result = result && (this.CardholderProleId.TrimOrNullify() == that.CardholderProleId.TrimOrNullify());
            return(result);
        }
コード例 #5
0
        /// <summary>
        ///     Creates a new <see cref="PaymentRecord" /> object instance that is a shallow-copy of the current object instance.
        /// </summary>
        /// <returns>
        ///     The shallow-copy of the current <see cref="PaymentRecord" /> object instance.
        /// </returns>
        public PaymentRecord Clone()
        {
            PaymentRecord record = new PaymentRecord();

            record.Id                  = this.Id;
            record.Lock                = this.Lock;
            record.AddDate             = this.AddDate;
            record.AddBy               = this.AddBy;
            record.ModDate             = this.ModDate;
            record.ModBy               = this.ModBy;
            record.RcvDate             = this.RcvDate;
            record.RcvFrom             = this.RcvFrom;
            record.CcardType           = this.CcardType;
            record.Name                = this.Name;
            record.Number              = this.Number;
            record.ExpyDte             = this.ExpyDte;
            record.AppvlRef            = this.AppvlRef;
            record.IssueNo             = this.IssueNo;
            record.CurrType            = this.CurrType;
            record.Recvd               = this.Recvd;
            record.RecvdBc             = this.RecvdBc;
            record.Date                = this.Date;
            record.Type                = this.Type;
            record.CustomerAcc         = this.CustomerAcc;
            record.UnusedVal           = this.UnusedVal;
            record.UnusedValBc         = this.UnusedValBc;
            record.GlCode              = this.GlCode;
            record.Period              = this.Period;
            record.OrderId             = this.OrderId;
            record.Hidden              = this.Hidden;
            record.ChequeNo            = this.ChequeNo;
            record.SortCode            = this.SortCode;
            record.Status              = this.Status;
            record.Notes               = this.Notes;
            record.ValidDate           = this.ValidDate;
            record.CurrRateBc          = this.CurrRateBc;
            record.CurrRateBc2         = this.CurrRateBc2;
            record.SelcoSpId           = this.SelcoSpId;
            record.MepId               = this.MepId;
            record.OrgId               = this.OrgId;
            record.PnId                = this.PnId;
            record.Ref                 = this.Ref;
            record.BookId              = this.BookId;
            record.CardSecId           = this.CardSecId;
            record.StartMonth          = this.StartMonth;
            record.StartYear           = this.StartYear;
            record.ExpyMonth           = this.ExpyMonth;
            record.ExpyYear            = this.ExpyYear;
            record.RefundPayId         = this.RefundPayId;
            record.RefundPayRef        = this.RefundPayRef;
            record.TxnType             = this.TxnType;
            record.BankingRef          = this.BankingRef;
            record.BatId               = this.BatId;
            record.BankChg             = this.BankChg;
            record.BankChgBc           = this.BankChgBc;
            record.BankChgBc2          = this.BankChgBc2;
            record.MepCrtBatId         = this.MepCrtBatId;
            record.RecvdBc2            = this.RecvdBc2;
            record.UnusedValBc2        = this.UnusedValBc2;
            record.CostCode            = this.CostCode;
            record.Purpose             = this.Purpose;
            record.SchnId              = this.SchnId;
            record.AddId               = this.AddId;
            record.ReverseRes          = this.ReverseRes;
            record.BankSortCode        = this.BankSortCode;
            record.BankAccount         = this.BankAccount;
            record.AccId               = this.AccId;
            record.AccTranRet          = this.AccTranRet;
            record.ExpBatId            = this.ExpBatId;
            record.Moto                = this.Moto;
            record.LtId                = this.LtId;
            record.MstcId              = this.MstcId;
            record.OriginalCustomerAcc = this.OriginalCustomerAcc;
            record.Token               = this.Token;
            record.VoucherType         = this.VoucherType;
            record.GatewayAccId        = this.GatewayAccId;
            record.CardholderProleId   = this.CardholderProleId;
            return(record);
        }
コード例 #6
0
 /// <summary>
 ///     Initialises a new <see cref="LocalPaymentChequeModel" /> instance.
 /// </summary>
 /// <param name="provider">
 ///     The business provider to which the business model is bound.
 /// </param>
 /// <param name="record">
 ///     The data record which is encapsulated by the business model.
 /// </param>
 internal LocalPaymentChequeModel(LocalProvider provider, PaymentRecord record) : base(provider, record)
 {
 }