you can set terms
This commit is contained in:
@@ -139,7 +139,11 @@
|
||||
:auto-ap/add-bank-account-locations {:txes add-general-ledger/add-bank-account-locations :requires [:auto-ap/add-transaction-rules]}
|
||||
|
||||
:auto-ap/convert-transactions {:txes-fn `add-general-ledger/convert-transactions :requires [:auto-ap/add-bank-account-locations]}
|
||||
:auto-ap/add-exclude-to-invoice {:txes add-general-ledger/add-exclude-to-invoice :requires [:auto-ap/convert-transactions]}}]
|
||||
:auto-ap/add-exclude-to-invoice {:txes add-general-ledger/add-exclude-to-invoice :requires [:auto-ap/convert-transactions]}
|
||||
:auto-ap/add-terms {:txes [[{:db/ident :vendor/terms
|
||||
:db/doc "How many days till you pay"
|
||||
:db/valueType :db.type/long
|
||||
:db/cardinality :db.cardinality/one}]]}}]
|
||||
(println "Conforming database...")
|
||||
(c/ensure-conforms conn norms-map)
|
||||
(when (not (seq args))
|
||||
|
||||
@@ -114,6 +114,7 @@
|
||||
{:fields {:id {:type :id}
|
||||
:name {:type 'String}
|
||||
:code {:type 'String}
|
||||
:terms {:type 'Int}
|
||||
:hidden {:type 'Boolean}
|
||||
|
||||
:print_as {:type 'String}
|
||||
@@ -517,6 +518,7 @@
|
||||
:add_vendor
|
||||
{:fields {:id {:type :id}
|
||||
:name {:type 'String}
|
||||
:terms {:type 'Int}
|
||||
:code {:type 'String}
|
||||
|
||||
:hidden {:type 'Boolean}
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
[clojure.set :as set]))
|
||||
|
||||
|
||||
(defn upsert-vendor [context {{:keys [id name hidden code print_as primary_contact secondary_contact address default_account_id invoice_reminder_schedule] :as in} :vendor} value]
|
||||
(defn upsert-vendor [context {{:keys [id name hidden terms code print_as primary_contact secondary_contact address default_account_id invoice_reminder_schedule] :as in} :vendor} value]
|
||||
(let [_ (println default_account_id)
|
||||
transaction [(remove-nils #:vendor {:db/id (if id
|
||||
id
|
||||
@@ -16,6 +16,7 @@
|
||||
:name name
|
||||
:code code
|
||||
:hidden hidden
|
||||
:terms terms
|
||||
:print-as print_as
|
||||
:default-account default_account_id
|
||||
:invoice-reminder-schedule (keyword invoice_reminder_schedule)
|
||||
|
||||
Reference in New Issue
Block a user