From 13bfd5624be00bfee396901b4d18b410c66a5438 Mon Sep 17 00:00:00 2001 From: Nate Hoffman Date: Tue, 20 Jan 2026 17:00:27 -0700 Subject: [PATCH 1/3] Add Log Request setting to Intacct blocks --- Intacct/BatchToJournal.ascx.cs | 16 +++++++++++++--- Intacct/BatchesToJournal.ascx.cs | 14 ++++++++++++-- 2 files changed, 25 insertions(+), 5 deletions(-) diff --git a/Intacct/BatchToJournal.ascx.cs b/Intacct/BatchToJournal.ascx.cs index 6fdc097..554bb62 100644 --- a/Intacct/BatchToJournal.ascx.cs +++ b/Intacct/BatchToJournal.ascx.cs @@ -75,6 +75,13 @@ namespace RockWeb.Plugins.rocks_kfs.Intacct Order = 3, Key = AttributeKey.LogResponse )] + [BooleanField( + "Log Request", + Description = "Flag indicating if the Intacct Request should be logged to the Exception Log", + DefaultBooleanValue = false, + Order = 3, + Key = AttributeKey.LogRequest )] + [LavaField( "Journal Memo Lava", Description = "Lava for the journal (or other receipt if configured) memo per line. Default: Batch.Id: Batch.Name", @@ -199,6 +206,7 @@ private static class AttributeKey public const string ExportMode = "ExportMode"; public const string UndepositedFundsAccount = "UndepositedFundsAccount"; public const string AccountGroupingMode = "AccountGroupingMode"; + public const string LogRequest = "LogRequest"; } #endregion Keys @@ -443,7 +451,8 @@ private List GetIntacctBankAccountIds() var postXml = checkingAccountList.GetBankAccountsXML( _intacctAuth, _financialBatch.Id, accountFields ); var endpoint = new IntacctEndpoint(); - var resultXml = endpoint.PostToIntacct( postXml ); + var logRequest = GetAttributeValue( AttributeKey.LogRequest ).AsBoolean(); + var resultXml = endpoint.PostToIntacct( postXml, logRequest ); return endpoint.ParseListCheckingAccountsResponse( resultXml, _financialBatch.Id ); } @@ -498,9 +507,10 @@ protected void btnExportToIntacct_Click( object sender, EventArgs e ) postXml = otherReceipt.CreateOtherReceiptXML( _intacctAuth, _financialBatch.Id, ref debugLava, ( PaymentMethod ) ddlPaymentMethods.SelectedValue.AsInteger(), groupingMode, bankAccountId, undepFundAccount, GetAttributeValue( AttributeKey.JournalMemoLava ) ); } - var resultXml = endpoint.PostToIntacct( postXml ); var logResponse = GetAttributeValue( AttributeKey.LogResponse ).AsBoolean(); - var success = endpoint.ParseEndpointResponse( resultXml, _financialBatch.Id, logResponse ); + var logRequest = GetAttributeValue( AttributeKey.LogRequest ).AsBoolean(); + var resultXml = endpoint.PostToIntacct( postXml, logResponse ); + var success = endpoint.ParseEndpointResponse( resultXml, _financialBatch.Id, logRequest ); if ( success ) { diff --git a/Intacct/BatchesToJournal.ascx.cs b/Intacct/BatchesToJournal.ascx.cs index d3ec62c..1de758a 100644 --- a/Intacct/BatchesToJournal.ascx.cs +++ b/Intacct/BatchesToJournal.ascx.cs @@ -90,6 +90,13 @@ namespace RockWeb.Plugins.rocks_kfs.Intacct Order = 4, Key = AttributeKey.LogResponse )] + [BooleanField( + "Log Request", + Description = "Flag indicating if the Intacct Request should be logged to the Exception Log", + DefaultBooleanValue = false, + Order = 3, + Key = AttributeKey.LogRequest )] + [BooleanField( "Enable Debug", Description = "Outputs the object graph to help create your Lava syntax.", @@ -228,6 +235,7 @@ private static class AttributeKey public const string ExportMode = "ExportMode"; public const string UndepositedFundsAccount = "UndepositedFundsAccount"; public const string AccountGroupingMode = "AccountGroupingMode"; + public const string LogRequest = "LogRequest"; } #endregion Keys @@ -491,7 +499,8 @@ private List GetIntacctBankAccountIds() var postXml = checkingAccountList.GetBankAccountsXML( _intacctAuth, this.BlockId, accountFields ); var endpoint = new IntacctEndpoint(); - var resultXml = endpoint.PostToIntacct( postXml ); + var logRequest = GetAttributeValue( AttributeKey.LogRequest ).AsBoolean(); + var resultXml = endpoint.PostToIntacct( postXml, logRequest ); return endpoint.ParseListCheckingAccountsResponse( resultXml, this.BlockId ); } @@ -687,7 +696,8 @@ protected void btnExportToIntacct_Click( object sender, EventArgs e ) postXml = otherReceipt.CreateOtherReceiptXML( _intacctAuth, batch.Id, ref debugLava, ( PaymentMethod ) ddlPaymentMethods.SelectedValue.AsInteger(), groupingMode, bankAccountId, undepFundAccount, GetAttributeValue( AttributeKey.JournalMemoLava ) ); } - var resultXml = endpoint.PostToIntacct( postXml ); + var logRequest = GetAttributeValue( AttributeKey.LogRequest ).AsBoolean(); + var resultXml = endpoint.PostToIntacct( postXml, logRequest ); var logResponse = GetAttributeValue( AttributeKey.LogResponse ).AsBoolean(); var success = endpoint.ParseEndpointResponse( resultXml, batch.Id, logResponse ); From 7a5ae8d9efedf5b49fda0720fe73b58232187f61 Mon Sep 17 00:00:00 2001 From: Nate Hoffman Date: Tue, 20 Jan 2026 18:06:38 -0700 Subject: [PATCH 2/3] Update order of new setting. --- Intacct/BatchToJournal.ascx.cs | 2 +- Intacct/BatchesToJournal.ascx.cs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Intacct/BatchToJournal.ascx.cs b/Intacct/BatchToJournal.ascx.cs index 554bb62..b8df4b3 100644 --- a/Intacct/BatchToJournal.ascx.cs +++ b/Intacct/BatchToJournal.ascx.cs @@ -79,7 +79,7 @@ namespace RockWeb.Plugins.rocks_kfs.Intacct "Log Request", Description = "Flag indicating if the Intacct Request should be logged to the Exception Log", DefaultBooleanValue = false, - Order = 3, + Order = 4, Key = AttributeKey.LogRequest )] [LavaField( diff --git a/Intacct/BatchesToJournal.ascx.cs b/Intacct/BatchesToJournal.ascx.cs index 1de758a..82bdcfa 100644 --- a/Intacct/BatchesToJournal.ascx.cs +++ b/Intacct/BatchesToJournal.ascx.cs @@ -94,7 +94,7 @@ namespace RockWeb.Plugins.rocks_kfs.Intacct "Log Request", Description = "Flag indicating if the Intacct Request should be logged to the Exception Log", DefaultBooleanValue = false, - Order = 3, + Order = 4, Key = AttributeKey.LogRequest )] [BooleanField( From bd8a7f1d10e9577448610a94ec0ab3454137b428 Mon Sep 17 00:00:00 2001 From: Guy Maness Date: Wed, 21 Jan 2026 15:12:34 -0500 Subject: [PATCH 3/3] Update Intacct/BatchToJournal.ascx.cs Co-authored-by: Nate H --- Intacct/BatchToJournal.ascx.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Intacct/BatchToJournal.ascx.cs b/Intacct/BatchToJournal.ascx.cs index b8df4b3..8bec8e7 100644 --- a/Intacct/BatchToJournal.ascx.cs +++ b/Intacct/BatchToJournal.ascx.cs @@ -509,8 +509,8 @@ protected void btnExportToIntacct_Click( object sender, EventArgs e ) var logResponse = GetAttributeValue( AttributeKey.LogResponse ).AsBoolean(); var logRequest = GetAttributeValue( AttributeKey.LogRequest ).AsBoolean(); - var resultXml = endpoint.PostToIntacct( postXml, logResponse ); - var success = endpoint.ParseEndpointResponse( resultXml, _financialBatch.Id, logRequest ); + var resultXml = endpoint.PostToIntacct( postXml, logRequest ); + var success = endpoint.ParseEndpointResponse( resultXml, _financialBatch.Id, logResponse ); if ( success ) {