indention, bugfix

Josha von Gizycki 5 years ago
parent 51d17faadc
commit 667d8002bc

@ -41,6 +41,7 @@
(defn exec-query! [qry params] (defn exec-query! [qry params]
(with-open [session (db/get-session @conn)] (with-open [session (db/get-session @conn)]
(println "executing query" qry "with params" params)
(devmode/send-to-bar (devmode/send-to-bar
(str (butiful-query qry) (str (butiful-query qry)
"<br>---Params---<br>" "<br>---Params---<br>"

@ -51,9 +51,9 @@
(comment (comment
(roles-with-levels-of-coc! "dev") (roles-with-levels-of-coc! "dev")
(neo4j/exec-query! roles-with-levels-of-coc! (neo4j/exec-query! roles-with-levels-of-coc!
{:coc_uuid (get coc-instance-uuids "dev") {:coc_uuid (get coc-instance-uuids "dev")
:roleschema_uuid (:role schema-uuids) :roleschema_uuid (:role schema-uuids)
:levelschema_uuid (:level schema-uuids)})) :levelschema_uuid (:level schema-uuids)}))
(neo4j/defquery coc (neo4j/defquery coc
"MATCH (coc:instance {uuid:{uuid}}) "MATCH (coc:instance {uuid:{uuid}})
@ -82,8 +82,8 @@
(if-let [prop (:p row)] (if-let [prop (:p row)]
(update instance (update instance
:properties :properties
conj (assoc prop :attr conj (assoc prop
(:a row))) :attr (:a row)))
instance)) instance))
instance instance
res))) res)))
@ -117,9 +117,9 @@
(comment (comment
(modules-with-comps! "140962fb-f55e-45ab-87fc-680c012bd8dc") (modules-with-comps! "140962fb-f55e-45ab-87fc-680c012bd8dc")
(neo4j/exec-query! modules-with-comps (neo4j/exec-query! modules-with-comps
{:level_uuid "140962fb-f55e-45ab-87fc-680c012bd8dc" {:level_uuid "140962fb-f55e-45ab-87fc-680c012bd8dc"
:moduleschema_uuid (:module schema-uuids) :moduleschema_uuid (:module schema-uuids)
:compschema_uuid (:component schema-uuids)})) :compschema_uuid (:component schema-uuids)}))
(neo4j/defquery modules-and-levels (neo4j/defquery modules-and-levels
"MATCH (role:instance {uuid:{role_uuid}}), "MATCH (role:instance {uuid:{role_uuid}}),
@ -151,7 +151,7 @@
(neo4j/defquery components-of-module (neo4j/defquery components-of-module
"MATCH (module:instance {uuid:{uuid}}), "MATCH (module:instance {uuid:{uuid}}),
(cschema:schema {uuid:{compschema_uuid}}), (cschema:schema {uuid:{compschema_uuid}}),
(comp:instance)-[:of]->(schema), (comp:instance)-[:of]->(cschema),
(module)--(:link)--(comp) (module)--(:link)--(comp)
RETURN comp RETURN comp
ORDER BY comp.name") ORDER BY comp.name")

Loading…
Cancel
Save