Data Layer low complexity mobile
0
Dependencies
1
Dependents
1
Entities
0
Integrations

Description

Lightweight local persistence layer for in-progress note drafts. Stores partial note content keyed by contact ID so that the editor can restore unsaved work after the app is backgrounded or crashed. Drafts are discarded automatically on successful submit or explicit discard.

Feature: Note Editor

notes-draft-store

Responsibilities

  • Persist draft note content and linked contact ID to local SQLite
  • Retrieve the most recent draft for a given contact or an unlinked draft
  • Remove a draft record on submit success or explicit discard
  • Provide a list of all pending drafts for coordinator review

Interfaces

saveDraft(draft: NoteDraft): Future<void>
getDraft(contactId?: string): Future<NoteDraft?>
deleteDraft(draftId: string): Future<void>
listAllDrafts(): Future<List<NoteDraft>>
clearExpiredDrafts(olderThanDays: int): Future<void>

Relationships

Dependents (1)

Components that depend on this component

Related Data Entities (1)

Data entities managed by this component