notesmachine/server/nm-store
Elf M. Sternberg da44610098 Reverse reference SQL written.
This is pretty hairy, because we're relying on the LEFT JOIN feature
to give us the root node when we need it.  That's kinda ugly, but
it seems to work just fine.  It also gives us the list in the
*correct* order, so the only thing we need to do is go to the last
item in the returned vector, make sure it's a root node, then go
fetch the page so we can decorate the list with the *right* root.
We'll pass this as a JSON object { [notes-in-reverse], page }.
2020-10-29 10:50:31 -07:00
..
docs FEAT Delete & Update note is now complete. 2020-10-26 18:54:56 -07:00
experiments Reverse reference SQL written. 2020-10-29 10:50:31 -07:00
src Reverse reference SQL written. 2020-10-29 10:50:31 -07:00
.gitignore DOC Phase one committed to the project, the basic layout of the backstore. 2020-09-27 05:35:37 -07:00
Cargo.toml MERGE Shrinkwrap and Comrak updates. 2020-10-13 18:03:12 -07:00
Makefile DOC Rustfmt works. 2020-09-29 08:08:30 -07:00
README.org Note/Page reference relationships now built. 2020-10-16 07:16:57 -07:00

README.org

Notesmachine Store

This is the storage layer for Notesmachine. It supports the retrieval of the basic information from Notesmachine, but it never reveals the underlying mechanisms by which it performs its magic. The "ids" leaving this API will always be the textual ids used in all public representations:

  • Boxes are referenced by slugs, and clients must accept uniqueness failures.
  • Notes are referenced by "friendly_id" format strings, which are base-62 formatted versions of UUID4 strings.

Plans

TODO Make it possible to connect two notes

TODO Make it possible to connect a note to a page

TODO Make it possible to retrieve a collection of notes

TODO Make it possible to retrieve a page