supports location matches, adds invoice types
This commit is contained in:
@@ -26,6 +26,8 @@
|
||||
[_ _ value]
|
||||
value)
|
||||
|
||||
(def last-text (atom nil))
|
||||
|
||||
|
||||
(defn template-applies? [text {:keys [keywords]}]
|
||||
(every? #(re-find % text) keywords))
|
||||
@@ -49,7 +51,7 @@
|
||||
:text text}))])))
|
||||
|
||||
(defn parse [text]
|
||||
(println text)
|
||||
(reset! last-text text)
|
||||
(->> t/pdf-templates
|
||||
(filter (partial template-applies? text))
|
||||
first
|
||||
|
||||
Reference in New Issue
Block a user