UCM Blog

Latest News and Updates from the Ultimate Client Manager team

Setting up “Custom Data” to appear on an Invoice template

In this tutorial we will pull some “Custom Data” elements into an invoice template.

  1. First we setup our data by going to Settings > Custom Data and creating a new data store. We will call this one “Commission Rates”. Our aim is to show the text “Dave: 10%” on our final invoice.
  2. Next we want to link one of these “Commission Rates” with a customer account. This will allow us to show our Custom Data text on any invoice generated for that customer. So we create a new extra field for customers and call it “Commission” like so:
  3. Then we go to Settings > Extra Fields > Commission in order to change the settings for this new extra field. We change the field type from “plain text” over to “ajax lookup” like this:
  4. To find the “Ajax Lookup” value we go back to Settings > Custom Data > Commission. and then choose the field you want to search on. I want to search based on the “Staff” name, so I open the settings for “Staff” and copy the “Extra Lookup” value from the bottom:
  5. Copy this value into the “Extra Settings” area like so:
  6. Now if you go to the Customer Edit page you can select one of your Custom Data commission rates from the extra field. Yay!
  7. Now to get this information displayed on the Invoice we go to Settings > Templates and open the external_invoice template. Add this text to the template:

    Commission Rate {COMMISSION.STAFF NAME} at {COMMISSION.COMMISSION}

    The first “{COMMISSION.” part references the extra field named “Commission” on the customer.
    The second “.STAFF NAME}” part references the name of the custom data field.

  8. This means {COMMISSION.STAFF NAME} will print Dave in the invoice template.
    And {COMMISSION.COMMISSION} will print 10% in the invoice template.
dtbakerSetting up “Custom Data” to appear on an Invoice template
Share this post