Pages

Wednesday, August 1, 2012

"View details" bug in collection letter and interest note forms

When you hit "View details" from the customer account number fields in one of the collection letter and interest note related fields, you'll open a form showing the customers open transactions and not the customer main data as expected.

The tables for collection letters and interest notes has two relations from their AccountNum fields; one for CustTable and one for CustTransOpen. For some reason AX chooses to base the view on the CustTransOpen relation.

You can fix this by adding the following code to the jumpRef method of the AccountNum field on the respective datasources:
public void jumpRef()
{
    // There are relations from the AccountNum field to both CustTable 
    // and CustTransOpen,
    // and AX chooses to use the CustTransOpen relations by default
    CustTable::jumpRefCustomer(CustInterestJour.AccountNum);
}

No comments: