コード例 #1
0
        public void Build(GAFRecordBase gafRecord, TaxAdjustment taxAdjustment, TaxTran taxTran, int lineNumber)
        {
            BuildInternal(gafRecord, taxTran, taxAdjustment.CuryID, lineNumber);

            gafRecord.InvoiceNumber       = taxAdjustment.RefNbr;
            gafRecord.InvoiceDate         = taxAdjustment.DocDate.Value;
            gafRecord.ProductDescription  = taxAdjustment.DocDesc;
            gafRecord.ForeignCurrencyCode = GetForeignCurrencyCode(taxAdjustment.CuryID);
        }
コード例 #2
0
        public void Build(GAFRecordBase gafRecord, GLTran glTran, string curyID, TaxTran taxTran, int lineNumber)
        {
            BuildInternal(gafRecord, taxTran, curyID, lineNumber);

            gafRecord.InvoiceNumber       = string.Concat(glTran.BatchNbr, glTran.RefNbr);
            gafRecord.InvoiceDate         = glTran.TranDate.Value;
            gafRecord.ProductDescription  = glTran.TranDesc;
            gafRecord.ForeignCurrencyCode = GetForeignCurrencyCode(curyID);
        }
コード例 #3
0
        protected void BuildInternal(GAFRecordBase gafRecord, TaxTran taxTran, string curyID, int lineNumber)
        {
            gafRecord.LineNumber = lineNumber;

            gafRecord.GSTAmount = taxTran.TaxAmt.Value;
            gafRecord.Amount    = taxTran.TaxableAmt.Value;

            gafRecord.ForeignCurrencyAmountGST = GetForeignCurrencyAmount(curyID, taxTran.CuryTaxAmt.Value);
            gafRecord.ForeignCurrencyAmount    = GetForeignCurrencyAmount(curyID, taxTran.CuryTaxableAmt.Value);

            gafRecord.TaxCode = taxTran.TaxID;
        }
コード例 #4
0
        protected void ApplySign(GAFRecordBase gafRecord, string taxTranModule, string docType)
        {
            var sign = ReportTaxProcess.GetMultByTranType(taxTranModule, docType);

            if (sign < 0)
            {
                gafRecord.Amount                   *= sign;
                gafRecord.GSTAmount                *= sign;
                gafRecord.ForeignCurrencyAmount    *= sign;
                gafRecord.ForeignCurrencyAmountGST *= sign;
            }
        }
コード例 #5
0
        private SortedList <int, object> BuildDocumentRecordsDataListToWrite(GAFRecordBase gafRecord)
        {
            var list = new SortedList <int, object>
            {
                { 30, gafRecord.InvoiceDate },
                { 40, gafRecord.InvoiceNumber },
                { 60, gafRecord.LineNumber },
                { 70, gafRecord.ProductDescription },
                { 80, RoundAmount(gafRecord.Amount) },
                { 90, RoundAmount(gafRecord.GSTAmount) },
                { 100, gafRecord.TaxCode },
                { 120, gafRecord.ForeignCurrencyCode },
                { 130, RoundAmount(gafRecord.ForeignCurrencyAmount, gafRecord.ForeignCurrencyCode) },
                { 140, RoundAmount(gafRecord.ForeignCurrencyAmountGST, gafRecord.ForeignCurrencyCode) }
            };

            return(list);
        }
コード例 #6
0
 public void Build(GAFRecordBase gafRecord, IRegister register)
 {
     gafRecord.InvoiceDate         = register.DocDate.Value;
     gafRecord.InvoiceNumber       = register.RefNbr;
     gafRecord.ForeignCurrencyCode = GetForeignCurrencyCode(register.CuryID);
 }