Some previous bugs with Billable Expenses were fixed. When testing, I discovered at least one still exists. This may or may not be related to a previous bug. The bug manifests when following this sequence:
- Create a billable expense, such as with a purchase invoice. Status of the expense shows as Uninvoiced.
- Invoice the billable expense from the Customers tab. Status changes to Invoiced. Invoice number is automatically filled in on the source transaction.
- Delete the resulting sales invoice (such as when there are unrelated mistakes, or you decide to include other billable expenses or time on the invoice).
After step #3, the status of the expense still shows as Invoiced in the Billable Expenses tab:
But no sales invoice exists:
Meanwhile, the source transaction shows a UUID for the invoice. This field was originally left at the default Uninvoiced, because no sales invoice had yet been created. It changed automatically to the sales invoice reference when the sales invoice was created from Customer. Now, it is incomprehensible:
and the Customers tab shows no uninvoiced balance for the customer, so a new sales invoice cannot be generated to replace the cancelled one:
The only recovery path seems to be to revisit the source transaction and delete the UUID in the