Normally you'd do a vendor credit or JE (with the AP line associated to the vendor). Then apply that to the open vendor bill (you can do this directly on the credit or by doing a zero-dollar payment if you did this via JE). If you're saying that the amounts are already written off via a JE and didn't get associated with a vendor at the time, then I'd probably just do a cleanup JE that debits and credits the AP account for the relevant amount tagging the vendor only on the Debit to AP. Then do a zero-dollar payment of the JE and the open vendor bill.