This commit is contained in:
2022-03-17 09:41:05 -07:00

View File

@@ -376,7 +376,6 @@
(let [message (str "The bank account " (:bank-account/name bank-account) " does not have a starting check number. Please ask the integreat staff to initialize it.")]
(throw (ex-info message
{:validation-error message}))))
_ (assert-none-locked client-id (map (comp c/to-date :invoice/date) invoices))
checks (->> (for [[[vendor-id invoices] index] (map vector invoices-grouped-by-vendor (range))]
(invoices->entities invoices (vendors vendor-id) client bank-account type index invoice-amounts))
(reduce into [])
@@ -434,7 +433,6 @@
(assert-can-see-client (:id context) (:invoice/client invoice)))
client-id (:db/id (:invoice/client (first invoices)))
_ (validate-belonging (:db/id (:client/_bank-accounts bank-account)) invoices bank-account)
_ (assert-none-locked client-id (map (comp c/to-date :invoice/date) invoices))
_ (assert-not-locked client-id (:date args))
invoice-payment-lookup (by :invoice_id :amount (:invoice_payments args))
base-payment (base-payment invoices