Using Apex for Automated Payment Numbering

Our friends at the Haas Jr. Fund finally decided they’re tired of having to manually sort and number their Grant Payment records.  After considering their options they asked us to help them come up with a solution for easy payment numbering.  We liked the end result so much that we decided we had to share it with everyone.

The basic requirement was that payments get automatically assigned numbers so that we can keep them organized.  The tricky part was ensuring that every payment gets a number and that the numbers get updated for all payments whenever a new payment is added or a payment is deleted.  After some work we came up with a solution that is both simple and effective.  The end result looks pretty much like this:

payment numbering

As you can see it looks nice and allows you to sort by the field called ‘Payment Number’.  Since the individual payment number and the total number of payments are two separate fields it allows for the option of whether or not the total number of payments is displayed at all.  Because options are important we also configured our solution to let you choose which date field is used to sort the payments.

That’s pretty much it, a simple solution for automating grant payment numbering which works even when using the Payment Wizard.  You can contact us if you’re interested in using this payment numbering solution!