Hello,
I am trying to create an api in laravel hitting our business central for an external site.
In the chart of accounts, the user wants to have a view of their total balance and net change. Then, they want to be able to filter down by dimensions. They should be able to have filter where they can toggle on a dimension, and choose a valueCode of that dimension to get the total net change and balance of ledgers containing the valueCode.
I've been able to hit into the general ledger, per account, expanding the dimensionSetLines to see codes and valueCodes.
It seems there isn't a way to only pull general ledger entries where the nested dimensionSetLines contains a dimension code, and a specific codeValue. Is this something that will have to be handled after retrieving all of the general ledgers?
Is there an easier way that I am not realizing for both of these? Right now I think I need to pull all of the accounts, then for each account, add the netChange, then, expand the trialBalance to add the balances, but if a filter is active, I grab all general ledgers per account, expand the dimensionSetLines to see the codes and filter the valueCode, and add the ledgers individually.
We also need date range filters, but that might be a battle for another day.
Thanks
Stay up to date on forum activity by subscribing. You can also customize your in-app and email Notification settings across all subscriptions.
André Arnaud de Cal... 291,134 Super User 2024 Season 2
Martin Dráb 229,928 Most Valuable Professional
nmaenpaa 101,156