private static ICCPaymentTransaction LastSuccessfulCCProcTranTran(int?extTranId, CCProcTranRepository repo) { var procTrans = repo.GetCCProcTranByTranID(extTranId).Cast <ICCPaymentTransaction>(); ICCPaymentTransaction paymentTran = CCProcTranHelper.FindCCLastSuccessfulTran(procTrans); return(paymentTran); }
public static bool HasVoidPreAuthorizedInHistory(PXGraph graph, IExternalTransaction extTran) { if (graph == null) { throw new ArgumentNullException(nameof(graph)); } if (extTran == null) { throw new ArgumentNullException(nameof(extTran)); } CCProcTranRepository repo = new CCProcTranRepository(graph); var history = repo.GetCCProcTranByTranID(extTran.TransactionID); return(CCProcTranHelper.HasVoidPreAuthorized(history)); }
public static bool HasOpenCCProcTran(PXGraph graph, IExternalTransaction extTran) { if (graph == null) { throw new ArgumentNullException(nameof(graph)); } if (extTran == null) { return(false); } CCProcTranRepository repo = new CCProcTranRepository(graph); var records = repo.GetCCProcTranByTranID(extTran.TransactionID); return(CCProcTranHelper.HasOpenCCTran(records)); }