grub-fork/database_schema.edn
Nicholas Kariniemi c1e0dfbf0b Switch to Datomic for storage (not persistent)
- Still not taking advantage of Datomic features but using it as a
  simple dump for Clojure data structures.
2015-07-04 22:22:47 +03:00

53 lines
1.5 KiB
Clojure

[
;; grubs
{:db/id #db/id[:db.part/db]
:db/ident :grub/id
:db/valueType :db.type/keyword
:db/cardinality :db.cardinality/one
:db/unique :db.unique/identity
:db/doc "Grub ID"
:db.install/_attribute :db.part/db}
{:db/id #db/id[:db.part/db]
:db/ident :grub/text
:db/valueType :db.type/string
:db/cardinality :db.cardinality/one
:db/fulltext true
:db/doc "The text of a grub item e.g. '3 apples'"
:db.install/_attribute :db.part/db}
{:db/id #db/id[:db.part/db]
:db/ident :grub/completed
:db/valueType :db.type/boolean
:db/cardinality :db.cardinality/one
:db/doc "The status of a grub item (completed or not completed)"
:db.install/_attribute :db.part/db}
;; recipes
{:db/id #db/id[:db.part/db]
:db/ident :recipe/id
:db/valueType :db.type/keyword
:db/cardinality :db.cardinality/one
:db/unique :db.unique/identity
:db/doc "Recipe ID"
:db.install/_attribute :db.part/db}
{:db/id #db/id[:db.part/db]
:db/ident :recipe/name
:db/valueType :db.type/string
:db/cardinality :db.cardinality/one
:db/fulltext true
:db/doc "Recipe name"
:db.install/_attribute :db.part/db}
{:db/id #db/id[:db.part/db]
:db/ident :recipe/grubs
:db/valueType :db.type/string
:db/cardinality :db.cardinality/one
:db/fulltext true
:db/doc "Recipe ingredients"
:db.install/_attribute :db.part/db}
{:db/id #db/id[:db.part/db]
:db/ident :recipe/directions
:db/valueType :db.type/string
:db/cardinality :db.cardinality/one
:db/fulltext true
:db/doc "Directions for making a recipe"
:db.install/_attribute :db.part/db}
]