diff --git a/src/clj/auto_ap/graphql/vendors.clj b/src/clj/auto_ap/graphql/vendors.clj index cb5f52f1..ae736b49 100644 --- a/src/clj/auto_ap/graphql/vendors.clj +++ b/src/clj/auto_ap/graphql/vendors.clj @@ -5,7 +5,8 @@ [datomic.api :as d] [auto-ap.datomic :refer [uri remove-nils audit-transact conn]] [clj-time.coerce :as coerce] - [clojure.set :as set])) + [clojure.set :as set] + [clojure.tools.logging :as log])) (defn upsert-vendor [context {{:keys [id name hidden terms code print_as primary_contact secondary_contact address default_account_id invoice_reminder_schedule schedule_payment_dom terms_overrides account_overrides] :as in} :vendor} value] @@ -87,6 +88,7 @@ {:db/id apwd}) (:automatically_paid_when_due in))])) + _ (log/info "Upserting vendor" transaction) transaction-result (audit-transact transaction (:id context))] (-> (d-vendors/get-by-id (or (-> transaction-result :tempids (get "vendor")) diff --git a/src/cljs/auto_ap/views/components/vendor_dialog.cljs b/src/cljs/auto_ap/views/components/vendor_dialog.cljs index 1e453c0d..6fa33e7f 100644 --- a/src/cljs/auto_ap/views/components/vendor_dialog.cljs +++ b/src/cljs/auto_ap/views/components/vendor_dialog.cljs @@ -425,6 +425,7 @@ :client (:client to) :override (:terms to)}) %)) + (update :automatically-paid-when-due #(mapv identity %)) (update :hidden #(if (nil? %) false %))