Exemplo n.º 1
0
        public XPCollection <Transaction> GetTransactionsAndRelatedTransactions(Session session, Guid billId)
        {
            try
            {
                XPCollection <Transaction> ret = null;
                XPCollection <Transaction> billTransactions      = null;
                XPCollection <Transaction> voucherTransactions   = null;
                XPCollection <Transaction> inventoryTransactions = null;

                PaymentVoucherTransactionBO paymentVoucherTransactionBO = new PaymentVoucherTransactionBO();

                //Get bill transactions
                billTransactions = GetTransactions(session, billId);
                //Get related voucher transactions
                voucherTransactions =
                    paymentVoucherTransactionBO.GetRelatedTransactionsWithBill(session, billId);
                //Get related inventory transactions...

                ret = billTransactions;

                if (voucherTransactions != null)
                {
                    ret.AddRange(voucherTransactions);
                }

                if (inventoryTransactions != null)
                {
                    ret.AddRange(inventoryTransactions);
                }

                return(ret);
            }
            catch (Exception)
            {
                throw;
            }
        }
Exemplo n.º 2
0
        public XPCollection <Transaction> GetVoucherTransactions(Session session, Guid billId)
        {
            PaymentVoucherTransactionBO paymentVoucherTransactionBO = new PaymentVoucherTransactionBO();

            return(paymentVoucherTransactionBO.GetRelatedTransactionsWithBill(session, billId));
        }