Handle orphaned documents when a taxed AP/AR Open Item is cancelled

Handle orphaned documents when a taxed AP/AR Open Item is cancelled.  Clear database entry.
@tjwebb  We try to put the pieces that help decide how to connect two tables to each other in the `JOIN` clause and the selection criteria - those that help restrict the output to the records of interest - in the `WHERE` clause. In this query, the `:womatl_id` is definitely a selection criterion - note the colon, indicating a parameter passed to the query from the caller/user.

The `wo_ordtype` is less clear, as it's compared to a constant and might reasonably be considered a selection criterion. Note that work orders may be created to fulfill other work orders or sales orders or .... Putting `wo_ordtype` in the `JOIN` tells the reader that only work orders created for other work orders are appropriately joined with the `womatl` table. It's unclear where this particular criterion belongs, but _I would lean toward the `WHERE` clause for this query in this context_.