adds due date column.
This commit is contained in:
@@ -508,6 +508,12 @@
|
||||
:show-starting "lg"
|
||||
:render (fn [{:invoice/keys [date]}]
|
||||
(some-> date (atime/unparse-local atime/normal-date)))}
|
||||
{:key "due"
|
||||
:sort-key "due"
|
||||
:name "Due"
|
||||
:show-starting "xl" ;; xl:table-cell
|
||||
:render (fn [{:invoice/keys [due]}]
|
||||
(some-> due (atime/unparse-local atime/normal-date)))}
|
||||
{:key "status"
|
||||
:name "Status"
|
||||
:render (fn [{:invoice/keys [status]}]
|
||||
|
||||
@@ -586,44 +586,51 @@
|
||||
|
||||
(defn index-solr
|
||||
[]
|
||||
(println "invoice")
|
||||
(doseq [batch (->> (dc/qseq {:query '[:find ?i
|
||||
:in $
|
||||
:where [?i :invoice/invoice-number]
|
||||
(not [?i :invoice/status :invoice-status/voided])]
|
||||
:args [(dc/db conn)]})
|
||||
(map first)
|
||||
(partition-all 1000))]
|
||||
(partition-all 500))]
|
||||
(print ".")
|
||||
(flush)
|
||||
(solr/index-documents solr/impl "invoices" batch))
|
||||
(println)
|
||||
|
||||
(println "payment")
|
||||
(doseq [batch (->> (dc/qseq {:query '[:find ?i
|
||||
:in $
|
||||
:where [?i :payment/date]
|
||||
(not [?i :payment/status :payment-status/voided])]
|
||||
:args [(dc/db conn)]})
|
||||
(map first)
|
||||
(partition-all 1000))]
|
||||
(partition-all 500))]
|
||||
(print ".")
|
||||
(flush)
|
||||
(solr/index-documents solr/impl "invoices" batch))
|
||||
(println)
|
||||
|
||||
(println "trans")
|
||||
(doseq [batch (->> (dc/qseq {:query '[:find ?i
|
||||
:in $
|
||||
:where [?i :transaction/description-original]
|
||||
(not [?i :transaction/approval-status :transaction-approval-status/suppressed])]
|
||||
:args [(dc/db conn)]})
|
||||
(map first)
|
||||
(partition-all 1000))]
|
||||
(partition-all 500))]
|
||||
(print ".")
|
||||
(flush)
|
||||
(solr/index-documents solr/impl "invoices" batch))
|
||||
(println)
|
||||
(println "journal")
|
||||
(doseq [batch (->> (dc/qseq {:query '[:find ?i
|
||||
:in $
|
||||
:where [?i :journal-entry/date]]
|
||||
:args [(dc/db conn)]})
|
||||
(map first)
|
||||
(partition-all 1000))]
|
||||
(partition-all 500))]
|
||||
(print ".")
|
||||
(flush)
|
||||
(solr/index-documents solr/impl "invoices" batch)))
|
||||
|
||||
Reference in New Issue
Block a user