tsbonev / nharker

NHaker - an offline writing organization tool
0 stars 0 forks source link

entries: connect an entry id to its owner article #138

Closed tsbonev closed 6 years ago

tsbonev commented 6 years ago

Currently the state of entries is in flux, articles have properties which contain the direct entry yet that same entry is persisted into the entry collection. Entries need to be separate from articles for searching reasons, there isn't a way (yet, future versions of nitriteDb might fix this) to index a collection, so the text search on an entry's text can only happen if it is in a collection of its own. This spawns the problem that an entry always has a parent article but doesn't know about its id.

1) Return the articleId to entries, which will allow for quick querying.

2) Look for a way to match any given entry's id with some article that contains it.