A great feature in GlobiFlow is the ability to create a Detail Table from a set of collected items within an App. This table can then be inserted into an HTML box found in the Send Email or Make a PDF actions. For this example, we are going to create a PDF Invoice, with a table of line items, that will be sent to clients.
When a Customer has a new job request, we create a Work Order. While the job is in progress, we create Time Sheets to bill time to the Work Order. Once the job has been completed, we must create an invoice with a unique ID number. This invoice can then be sent to the customer and uploaded into our accounting system.
1. First a Category field called Status was placed on our Work Orders App which acts like an action button. This Status will be changed in order to create an Invoice Item within the Invoices app.
2. Once the Invoice Item has been created, a PDF file can be generated using the data from all related timesheet items. The Invoice Item will have a unique ID which can be used for the Invoice Number. This can be set up in the Advanced tab of the App Settings. The field token associated with this number is called the Podio App Item ID. Using the (Formatted) choice will reflect this Unique ID with the format chosen in the settings.
1. The first flow created is in the Work Order App. The filters state this flow will run when the Status category has changed and is equal to â€œCompletedâ€. If so, we first need to collect the Client Item for data so that we can perform a calculation on the Amount Due. Then Invoice Item is then created with a relationship to the Work Order and Client App. Be sure all important fields for the PDF Invoice are filled out in this step.
2. Now, set up a flow to run upon Item creation in the Invoice App. No filters are being set as we want this to run on every Invoice Item.
2a. The first step is to collect the referenced Time Sheets using the Get Referenced Item(s) collector. In our example, we have collected the Time Sheets that have a relationship to the Work Order that is being referenced by the Invoice. We have also added a collector to get the Client data to open up the field tokens to use on the Invoice.
2b. Then create a Detail Table using these Time Sheet Items. Select which fields should be added for column headings.
2c. Finally, add the Make a PDF action. Create the PDF body and use the Field Token selector to add specific fields from the Apps and to add the HTML Detail Table.
Note: You can use Custom Variables to re-format fields that don't come out of Podio the way you want them displayed.
Once the Work Order Status is set to Complete, the invoice record is created, triggering the flow to create the PDF file. This file is then attached to the invoice record and can be emailed in a Send Email Action if desired. Here's a sample resulting PDF invoice: