A bunch of bug fixes.
This commit is contained in:
@@ -164,3 +164,26 @@
|
||||
#_(process-all)
|
||||
|
||||
#_(reset! break true)
|
||||
|
||||
|
||||
|
||||
(defn keep-up-to-date []
|
||||
(while (and (not @break)
|
||||
(not (Thread/interrupted)))
|
||||
(try
|
||||
@(d/transact
|
||||
(d/connect uri)
|
||||
(mapv
|
||||
#(auto-ap.ledger/entity-change->ledger (d/db (d/connect uri)) [:transaction %])
|
||||
(concat
|
||||
(->>
|
||||
(d/query {:query {:find ['?t ]
|
||||
:in ['$]
|
||||
:where ['[?t :transaction/date]
|
||||
'(not [?t :transaction/approval-status :transaction-approval-status/excluded])
|
||||
'(not-join [?t] [?e :journal-entry/original-entity ?t])]}
|
||||
:args [(d/db (d/connect uri))]})
|
||||
(map first)))))
|
||||
(Thread/sleep 60000)
|
||||
(catch Exception e
|
||||
(println (.toString e))))))
|
||||
|
||||
Reference in New Issue
Block a user