|
|
|
@ -13,14 +13,12 @@
|
|
|
|
|
(defn list! [schema-uuid req]
|
|
|
|
|
(view/list! (domain-schema/find-by-uuid! schema-uuid)
|
|
|
|
|
(domain/find-by-schema! schema-uuid)
|
|
|
|
|
(forms-inst/new-form schema-uuid
|
|
|
|
|
(domain-attr/required! schema-uuid))
|
|
|
|
|
(forms-inst/with-attributes (domain-attr/required! schema-uuid))
|
|
|
|
|
req))
|
|
|
|
|
|
|
|
|
|
(defn new! [req]
|
|
|
|
|
(let [schema-uuid (get-in req [:params :schema-uuid])
|
|
|
|
|
form-def (forms-inst/new-form schema-uuid
|
|
|
|
|
(domain-attr/required! schema-uuid))]
|
|
|
|
|
form-def (forms-inst/with-attributes (domain-attr/required! schema-uuid))]
|
|
|
|
|
(if (form/valid? form-def req)
|
|
|
|
|
(let [form-data (form/form-data form-def req)
|
|
|
|
|
req-attrs (domain-attr/required! schema-uuid)
|
|
|
|
|