makes sales queries go for 120 days, fixes Youngs Market

This commit is contained in:
Bryce
2023-10-20 22:15:06 -07:00
parent 6059e8a4ca
commit e66d93989c
3 changed files with 12 additions and 9 deletions

View File

@@ -246,7 +246,7 @@
:with ?s
:in $
:where
[(ground (iol-ion.query/recent-date)) ?min-d]
[(ground (iol-ion.query/recent-date 120)) ?min-d]
[(ground #inst \"2040-01-01\") ?max-d]
[?c :client/code \"%s\"]
[(iol-ion.query/sales-orders-in-range $ ?c ?min-d ?max-d) [?s ...]]
@@ -265,7 +265,7 @@
:with ?s ?li
:in $
:where
[(ground (iol-ion.query/recent-date)) ?min-d]
[(ground (iol-ion.query/recent-date 120)) ?min-d]
[(ground #inst \"2040-01-01\") ?max-d]
[?c :client/code \"%s\"]
[(iol-ion.query/sales-orders-in-range $ ?c ?min-d ?max-d) [?s ...]]
@@ -282,7 +282,7 @@
"[:find ?d4 ?t ?f
:in $
:where
[(ground (iol-ion.query/recent-date)) ?min-d]
[(ground (iol-ion.query/recent-date 120)) ?min-d]
[?c :client/code \"%s\"]
[?s :expected-deposit/client ?c]
[?s :expected-deposit/sales-date ?date]
@@ -297,7 +297,7 @@
:with ?charge
:in $
:where
[(ground (iol-ion.query/recent-date)) ?min-d]
[(ground (iol-ion.query/recent-date 120)) ?min-d]
[?c :client/code \"%s\"]
[?s :sales-order/client ?c]
[?s :sales-order/date ?date]
@@ -317,7 +317,7 @@
:with ?charge
:in $
:where
[(ground (iol-ion.query/recent-date)) ?min-d]
[(ground (iol-ion.query/recent-date 120)) ?min-d]
[?charge :charge/date ?date]
[(>= ?date ?min-d)]
[?charge :charge/client ?c]
@@ -344,7 +344,7 @@
:with ?r
:in $
:where
[(ground (iol-ion.query/recent-date)) ?min-d]
[(ground (iol-ion.query/recent-date 120)) ?min-d]
[?r :sales-refund/client [:client/code \"%s\"]]
[?r :sales-refund/date ?date]
[(>= ?date ?min-d)]
@@ -360,7 +360,7 @@
:in $
:where
[?cds :cash-drawer-shift/date ?date]
[(ground (iol-ion.query/recent-date)) ?min-d]
[(ground (iol-ion.query/recent-date 120)) ?min-d]
[(>= ?date ?min-d)]
[?cds :cash-drawer-shift/client [:client/code \"%s\"]]
[?cds :cash-drawer-shift/paid-in ?paid-in]

View File

@@ -273,7 +273,8 @@
:account-number #"Store Number:\s+(\d+)"
:invoice-number #"(?:INVOICE|CREDIT) DATE\n(?:.*?)\s{2,}(\d+?)\s+\S+\n"
:total #"Net Amount(?:.*\n){4}(?:.*?)([\-]?[0-9\.]+)\n"}
:parser {:date [:clj-time "dd-MMM-yy"]
:parser {:date [:clj-time ["MM/dd/yy"
"dd-MMM-yy"]]
:total [:trim-commas-and-negate nil]}}
;; WINE WAREHOUSE

View File

@@ -1,3 +1,5 @@
#!/bin/bash
sudo docker run --rm -ti -v ~/dev/integreat/data/solr:/var/solr --network=bridge -p 8983:8983 solr
#sudo docker run --rm -ti -v ~/dev/integreat/data/solr:/var/solr --network=bridge -p 8983:8983 solr
sudo podman container run --user 1000 --privileged --volume /home/notid/dev/integreat/data/solr:/var/solr -p 8983:8983 solr