Dear Sir
I Would Like to add Account Name to the CustLedgerTrans.Report
that is present in AX 2012 in the model Accounts receivable
underReports - > Transactions à Customer à History By Transactions
I have add AccountName to the table CustLedgerTransTmp I Move AccountName from Extended Data Type to the CustLedgerTransTmp
I have added new relation to table CustLedgerTransTmp
Called MainAccount(user)
CustLedgerTransTmp.MainAccountId == MainAccount.MainAccountId
And I have Modify those lines to CustLedgerTransDP Classes
In the Method ClassDeclaration I have added those lines
[
SRSReportQueryAttribute(queryStr(CustLedgerTrans)),
SRSReportParameterAttribute(classStr(CustLedgerTransContract))
]
publicclass CustLedgerTransDP extends SRSReportDataProviderBase
{
CustLedgerTransTmp custLedgerTransTmp;
/* Add by Jamil */
MainAccount mainaccount;
DimensionAttributeValueCombination _dimensionAttributeValueCombination;
/* End */
boolean totals;
boolean showOnlyMainAccount;
BillingClassification billingClassification;
}
And in the Method insertCustLedgerTransTmp I have added those lines
privatevoid insertCustLedgerTransTmp(CustName _custName,
CustTrans _custTrans,
LedgerPostingType _postingType,
boolean _isCredit,
AmountCur _transactionCurrencyAmount,
AmountMst _accountingCurrencyAmount,
MainAccountNum _mainAccountId,
DimensionDisplayValue _fullyQualifiedAccount,
TraceNum _traceNum)
{
custLedgerTransTmp.clear();
// Added by Jamil
select * FROM mainaccount
WHERE mainaccount.MainAccountId == _dimensionAttributeValueCombination.DisplayValue;
info('Name',mainaccount.Name);
pause ;
custLedgerTransTmp.AccountName = mainaccount.Name ;
/* End of modification */
After I have added the field custLedgerTransTmp.AccountName to the report CustLedgerTrans.Report it display blank not data have been display
Waiting for your valuable replay
Best Regards
Jamil