public void Test() { SummaryReconciliationRequestFactory factory = new SummaryReconciliationRequestFactory(); summaryReconciliationRequest request = new summaryReconciliationRequest(); summaryReconciliationResponse response = new summaryReconciliationResponse(); SummaryReconciliationClienService service = new SummaryReconciliationClienService(); factory.request.requestHeader.clientIPAddress = ("4.4.4.4"); factory.request.reconciliationDate = ("20160404"); factory.request.totalSaleAmount = ("0"); factory.request.totalReverseAmount = ("0"); factory.request.totalRefundAmount = ("0"); factory.request.totalSaleCountSpecified = true; factory.request.totalRefundCountSpecified = true; factory.request.totalReverseCountSpecified = false; factory.request.totalSaleCount = 0; factory.request.totalReverseCount = 0; factory.request.totalRefundCount = 0; request = factory.Build(); response = service.SoapClient(request); Assert.IsNotNull(response); }
protected summaryReconciliationResponse SummaryReconciliation_Method() { SummaryReconciliationRequestFactory factory = new SummaryReconciliationRequestFactory(); summaryReconciliationRequest request = new summaryReconciliationRequest(); summaryReconciliationResponse response = new summaryReconciliationResponse(); SummaryReconciliationClienService service = new SummaryReconciliationClienService(); try { factory.request.reconciliationDate = reconciliationDate; factory.request.totalSaleAmount = totalSaleAmount; factory.request.totalReverseAmount = totalReverseAmount; factory.request.totalRefundAmount = totalRefundAmount; factory.request.totalSaleCountSpecified = true; factory.request.totalRefundCountSpecified = true; factory.request.totalReverseCountSpecified = true; factory.request.totalSaleCount = Int32.Parse(totalSaleCount); factory.request.totalReverseCount = Int32.Parse(totalReverseCount); factory.request.totalRefundCount = Int32.Parse(totalRefundCount); if (totalPostAuthCount != "" || totalPostAuthReverseCount != "" || totalPreAuthCount != "" || totalPreAuthReverseCount != "" || totalPostAuthAmount != "" || totalPreAuthAmount != "" || totalPreAuthReverseAmount != "") { if (totalPostAuthCount != "") { factory.request.totalPostAuthCountSpecified = true; factory.request.totalPostAuthCount = Int32.Parse(totalPostAuthCount); } if (totalPostAuthReverseCount != "") { factory.request.totalPostAuthReverseCountSpecified = true; factory.request.totalPostAuthReverseCount = Int32.Parse(totalPostAuthReverseCount); } if (totalPreAuthCount != "") { factory.request.totalPreAuthCountSpecified = true; factory.request.totalPreAuthCount = Int32.Parse(totalPreAuthCount); } if (totalPreAuthReverseCount != "") { factory.request.totalPreAuthReverseCountSpecified = true; factory.request.totalPreAuthReverseCount = Int32.Parse(totalPreAuthReverseCount); } factory.request.totalPostAuthAmount = totalPostAuthAmount; factory.request.totalPreAuthAmount = totalPreAuthAmount; factory.request.totalPreAuthReverseAmount = totalPreAuthReverseAmount; } request = factory.Build(); response = service.OptionalRequest(MySession.Current.requestFilter, request); return(response); } catch (Exception ex) { ShowMessage(ex.Message); return(null); } }