looking good.
This commit is contained in:
@@ -11,6 +11,8 @@
|
||||
(map db->clj (j/query conn "SELECT * FROM invoices")))
|
||||
|
||||
|
||||
(defn get-unpaid []
|
||||
(map db->clj (j/query conn "SELECT * FROM invoices WHERE imported=true")))
|
||||
|
||||
(defn get-pending []
|
||||
(println conn)
|
||||
(map db->clj (j/query conn "SELECT * FROM invoices WHERE imported=0")))
|
||||
(map db->clj (j/query conn "SELECT * FROM invoices WHERE imported=false or imported is null")))
|
||||
|
||||
@@ -21,14 +21,19 @@
|
||||
[(keyword (kebab->snake (name k))) v])
|
||||
x)))
|
||||
|
||||
(def conn {:classname "org.postgresql.Driver" ; must be in classpath
|
||||
:dbtype "postgresql"
|
||||
:ssl true
|
||||
:sslfactory "org.postgresql.ssl.NonValidatingFactory"
|
||||
:host "ec2-54-235-123-153.compute-1.amazonaws.com"
|
||||
:port 5342
|
||||
:dbname "dbfemhppkdksfp"
|
||||
; Any additional keys are passed to the driver
|
||||
(let [db-host "ec2-54-235-123-153.compute-1.amazonaws.com"
|
||||
db-port 5432
|
||||
db-name "dbfemhppkdksfp"]
|
||||
|
||||
(def conn {:classname "org.postgresql.Driver" ; must be in classpath
|
||||
:ssl true
|
||||
:sslfactory "org.postgresql.ssl.NonValidatingFactory"
|
||||
:subprotocol "postgresql"
|
||||
:subname (str "//" db-host ":" db-port "/" db-name)
|
||||
; Any additional
|
||||
; keys are passed
|
||||
; to the driver
|
||||
; as driver-specific properties.
|
||||
:user "tkilrhrhzlumol"
|
||||
:password "de6117f8551364ac84ed31c1231941f53ab0b5470c9956f478b2025ab5a0fb8b"})
|
||||
:user "tkilrhrhzlumol"
|
||||
:password "de6117f8551364ac84ed31c1231941f53ab0b5470c9956f478b2025ab5a0fb8b"}))
|
||||
|
||||
|
||||
Reference in New Issue
Block a user