diff --git a/src/wanijo/framework/form.clj b/src/wanijo/framework/form.clj index f680a58..6851e47 100644 --- a/src/wanijo/framework/form.clj +++ b/src/wanijo/framework/form.clj @@ -47,7 +47,7 @@ (field form-def field-id req (get-in req [:params field-id]))) ([form-def field-id req field-value] - {:pre [(spec/valid? ::form form-def)]} + {:pre [(spec/valid? ::form form-def)]} (let [field-def (get-in form-def [:fields field-id]) {:keys [label required] spec-key :spec} field-def] (list (when-not (field-valid? field-value spec-key req) diff --git a/src/wanijo/framework/neo4j.clj b/src/wanijo/framework/neo4j.clj index 2877531..a32a539 100644 --- a/src/wanijo/framework/neo4j.clj +++ b/src/wanijo/framework/neo4j.clj @@ -26,7 +26,7 @@ clojure.string/trim-newline clojure.string/split-lines (map clojure.string/trim) - (filter #(> (count %) 0)) + (filter #(pos? (count %))) (clojure.string/join \newline))) (defn exec-query! [qry params] diff --git a/src/wanijo/framework/view.clj b/src/wanijo/framework/view.clj index 60ab297..87d7a4f 100644 --- a/src/wanijo/framework/view.clj +++ b/src/wanijo/framework/view.clj @@ -6,9 +6,9 @@ (defn btnlink ([target caption] (btnlink target caption "")) - ([target caption class] + ([target caption clss] [:a {:href target} - [:button {:class class} + [:button {:class clss} caption]])) (defn layout! diff --git a/src/wanijo/schema/domain.clj b/src/wanijo/schema/domain.clj index 3a6cc8c..824c5f9 100644 --- a/src/wanijo/schema/domain.clj +++ b/src/wanijo/schema/domain.clj @@ -32,12 +32,12 @@ SET s.created_at = {created_at} RETURN s") -(defn create-new! [name user-uuid] +(defn create-new! [schema-name user-uuid] (->> (neo4j/exec-query! create-new {:u_uuid user-uuid - :name name + :name schema-name :s_uuid (neo4j/uuid) :created_at (neo4j/now-str)}) first diff --git a/src/wanijo/user/domain.clj b/src/wanijo/user/domain.clj index 3787d3a..44753f1 100644 --- a/src/wanijo/user/domain.clj +++ b/src/wanijo/user/domain.clj @@ -17,7 +17,7 @@ RETURN n") (defn find! [ident] - (->> + (->> (neo4j/exec-query! find-user {:ident ident})