Files
buildfor_life_ops/graphify-out/cache/c918363f4c147df80e03b1c72bade533a246b4dfc620dade6923dd71b451450b.json
grabowski b59904fdae Phases 1-5 + rooms/floors, accounts, custom types, users, notifications
Data model
- Properties, rooms (+optional floors), assets (typed custom fields + Zod
  runtime validator + move history), documents (polymorphic scope)
- Projects -> work packages -> tasks -> subtasks
- Decision events (scoped to project/property/asset/work_package)
- Checklist templates + instances, maintenance schedules (time + usage) with
  auto-materialized checklists on event recording
- Wiki (global + per-project) with revisions + tsvector FTS
- Property accounts (utility/meter numbers by kind)
- Notifications table + per-user channel prefs

Infra
- RBAC guards (requireCompany / requireAdmin)
- Storage abstraction: LocalDiskStorage (HMAC signed URLs) + S3Storage
  behind the same interface, switchable via STORAGE_BACKEND
- CSV export for assets / maintenance / decisions
- QR labels: /api/qr SVG endpoint + printable /assets/[id]/label
- Notifications: in-app + SMTP (own server via nodemailer) + Matrix
  (Client-Server API, per-company room) with opt-in per user
- Company switcher + auto-select first company on login

UI
- Topbar: bell with unread count, theme toggle, name, Sign Out (flat)
- Sidebar: main nav + dedicated Admin section (Asset types, Users, Company)
- Nested-route tabs on property / project / asset detail pages
- Admin UIs for users (invite, role, reset pw, deactivate) and company
  settings (default currency, Matrix room id)
- Custom asset type creation + field-def editor with immutable key/type
  guard and auto-deprecate when removing a field still referenced

Graph
- graphify-out/ committed: GRAPH_REPORT.md, graph.html, graph.json
2026-04-23 15:18:11 +07:00

1 line
19 KiB
JSON

{"nodes": [{"id": "src_lib_server_services_notifications_ts", "label": "notifications.ts", "file_type": "code", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L1"}, {"id": "notifications_parsesettings", "label": "parseSettings()", "file_type": "code", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L31"}, {"id": "notifications_absolutelink", "label": "absoluteLink()", "file_type": "code", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L40"}, {"id": "notifications_notify", "label": "notify()", "file_type": "code", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L51"}, {"id": "notifications_fanoutexternal", "label": "fanOutExternal()", "file_type": "code", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L70"}, {"id": "notifications_renderemailhtml", "label": "renderEmailHtml()", "file_type": "code", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L125"}, {"id": "notifications_unreadcountforuser", "label": "unreadCountForUser()", "file_type": "code", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L144"}, {"id": "notifications_listforuser", "label": "listForUser()", "file_type": "code", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L161"}, {"id": "notifications_markread", "label": "markRead()", "file_type": "code", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L176"}, {"id": "notifications_markallread", "label": "markAllRead()", "file_type": "code", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L190"}, {"id": "notifications_updateuserprefs", "label": "updateUserPrefs()", "file_type": "code", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L211"}, {"id": "notifications_getuserprefs", "label": "getUserPrefs()", "file_type": "code", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L229"}], "edges": [{"source": "src_lib_server_services_notifications_ts", "target": "drizzle_orm", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L1", "weight": 1.0}, {"source": "src_lib_server_services_notifications_ts", "target": "env", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L2", "weight": 1.0}, {"source": "src_lib_server_services_notifications_ts", "target": "client", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L3", "weight": 1.0}, {"source": "src_lib_server_services_notifications_ts", "target": "tenancy", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L4", "weight": 1.0}, {"source": "src_lib_server_services_notifications_ts", "target": "notifications", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L5", "weight": 1.0}, {"source": "src_lib_server_services_notifications_ts", "target": "email", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L6", "weight": 1.0}, {"source": "src_lib_server_services_notifications_ts", "target": "matrix", "relation": "imports_from", "confidence": "EXTRACTED", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L7", "weight": 1.0}, {"source": "src_lib_server_services_notifications_ts", "target": "notifications_parsesettings", "relation": "contains", "confidence": "EXTRACTED", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L31", "weight": 1.0}, {"source": "src_lib_server_services_notifications_ts", "target": "notifications_absolutelink", "relation": "contains", "confidence": "EXTRACTED", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L40", "weight": 1.0}, {"source": "src_lib_server_services_notifications_ts", "target": "notifications_notify", "relation": "contains", "confidence": "EXTRACTED", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L51", "weight": 1.0}, {"source": "src_lib_server_services_notifications_ts", "target": "notifications_fanoutexternal", "relation": "contains", "confidence": "EXTRACTED", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L70", "weight": 1.0}, {"source": "src_lib_server_services_notifications_ts", "target": "notifications_renderemailhtml", "relation": "contains", "confidence": "EXTRACTED", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L125", "weight": 1.0}, {"source": "src_lib_server_services_notifications_ts", "target": "notifications_unreadcountforuser", "relation": "contains", "confidence": "EXTRACTED", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L144", "weight": 1.0}, {"source": "src_lib_server_services_notifications_ts", "target": "notifications_listforuser", "relation": "contains", "confidence": "EXTRACTED", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L161", "weight": 1.0}, {"source": "src_lib_server_services_notifications_ts", "target": "notifications_markread", "relation": "contains", "confidence": "EXTRACTED", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L176", "weight": 1.0}, {"source": "src_lib_server_services_notifications_ts", "target": "notifications_markallread", "relation": "contains", "confidence": "EXTRACTED", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L190", "weight": 1.0}, {"source": "src_lib_server_services_notifications_ts", "target": "notifications_updateuserprefs", "relation": "contains", "confidence": "EXTRACTED", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L211", "weight": 1.0}, {"source": "src_lib_server_services_notifications_ts", "target": "notifications_getuserprefs", "relation": "contains", "confidence": "EXTRACTED", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L229", "weight": 1.0}, {"source": "notifications_notify", "target": "notifications_fanoutexternal", "relation": "calls", "confidence": "EXTRACTED", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L65", "weight": 1.0}, {"source": "notifications_fanoutexternal", "target": "notifications_absolutelink", "relation": "calls", "confidence": "EXTRACTED", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L85", "weight": 1.0}, {"source": "notifications_fanoutexternal", "target": "notifications_parsesettings", "relation": "calls", "confidence": "EXTRACTED", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L111", "weight": 1.0}], "raw_calls": [{"caller_nid": "notifications_parsesettings", "callee": "parse", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L34"}, {"caller_nid": "notifications_absolutelink", "callee": "test", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L42"}, {"caller_nid": "notifications_absolutelink", "callee": "replace", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L43"}, {"caller_nid": "notifications_absolutelink", "callee": "startsWith", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L43"}, {"caller_nid": "notifications_notify", "callee": "map", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L54"}, {"caller_nid": "notifications_notify", "callee": "values", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L62"}, {"caller_nid": "notifications_notify", "callee": "insert", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L62"}, {"caller_nid": "notifications_notify", "callee": "catch", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L65"}, {"caller_nid": "notifications_fanoutexternal", "callee": "isEmailConfigured", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L71"}, {"caller_nid": "notifications_fanoutexternal", "callee": "isMatrixConfigured", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L71"}, {"caller_nid": "notifications_fanoutexternal", "callee": "where", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L73"}, {"caller_nid": "notifications_fanoutexternal", "callee": "from", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L73"}, {"caller_nid": "notifications_fanoutexternal", "callee": "select", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L73"}, {"caller_nid": "notifications_fanoutexternal", "callee": "and", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L83"}, {"caller_nid": "notifications_fanoutexternal", "callee": "inArray", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L83"}, {"caller_nid": "notifications_fanoutexternal", "callee": "eq", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L83"}, {"caller_nid": "notifications_fanoutexternal", "callee": "isEmailConfigured", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L89"}, {"caller_nid": "notifications_fanoutexternal", "callee": "all", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L90"}, {"caller_nid": "notifications_fanoutexternal", "callee": "map", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L91"}, {"caller_nid": "notifications_fanoutexternal", "callee": "filter", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L91"}, {"caller_nid": "notifications_fanoutexternal", "callee": "isMatrixConfigured", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L105"}, {"caller_nid": "notifications_fanoutexternal", "callee": "limit", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L106"}, {"caller_nid": "notifications_fanoutexternal", "callee": "where", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L106"}, {"caller_nid": "notifications_fanoutexternal", "callee": "from", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L106"}, {"caller_nid": "notifications_fanoutexternal", "callee": "select", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L106"}, {"caller_nid": "notifications_fanoutexternal", "callee": "eq", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L109"}, {"caller_nid": "notifications_fanoutexternal", "callee": "map", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L113"}, {"caller_nid": "notifications_fanoutexternal", "callee": "filter", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L113"}, {"caller_nid": "notifications_fanoutexternal", "callee": "sendMatrixMessage", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L116"}, {"caller_nid": "notifications_renderemailhtml", "callee": "join", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L131"}, {"caller_nid": "notifications_renderemailhtml", "callee": "esc", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L133"}, {"caller_nid": "notifications_renderemailhtml", "callee": "esc", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L134"}, {"caller_nid": "notifications_renderemailhtml", "callee": "esc", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L136"}, {"caller_nid": "notifications_unreadcountforuser", "callee": "where", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L148"}, {"caller_nid": "notifications_unreadcountforuser", "callee": "from", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L148"}, {"caller_nid": "notifications_unreadcountforuser", "callee": "select", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L148"}, {"caller_nid": "notifications_unreadcountforuser", "callee": "count", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L149"}, {"caller_nid": "notifications_unreadcountforuser", "callee": "and", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L152"}, {"caller_nid": "notifications_unreadcountforuser", "callee": "eq", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L153"}, {"caller_nid": "notifications_unreadcountforuser", "callee": "eq", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L154"}, {"caller_nid": "notifications_unreadcountforuser", "callee": "isNull", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L155"}, {"caller_nid": "notifications_unreadcountforuser", "callee": "Number", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L158"}, {"caller_nid": "notifications_listforuser", "callee": "limit", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L166"}, {"caller_nid": "notifications_listforuser", "callee": "orderBy", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L166"}, {"caller_nid": "notifications_listforuser", "callee": "where", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L166"}, {"caller_nid": "notifications_listforuser", "callee": "from", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L166"}, {"caller_nid": "notifications_listforuser", "callee": "select", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L166"}, {"caller_nid": "notifications_listforuser", "callee": "and", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L170"}, {"caller_nid": "notifications_listforuser", "callee": "eq", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L170"}, {"caller_nid": "notifications_listforuser", "callee": "eq", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L170"}, {"caller_nid": "notifications_listforuser", "callee": "desc", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L172"}, {"caller_nid": "notifications_markread", "callee": "where", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L178"}, {"caller_nid": "notifications_markread", "callee": "set", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L178"}, {"caller_nid": "notifications_markread", "callee": "update", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L178"}, {"caller_nid": "notifications_markread", "callee": "sql", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L180"}, {"caller_nid": "notifications_markread", "callee": "and", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L182"}, {"caller_nid": "notifications_markread", "callee": "eq", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L183"}, {"caller_nid": "notifications_markread", "callee": "inArray", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L184"}, {"caller_nid": "notifications_markread", "callee": "isNull", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L185"}, {"caller_nid": "notifications_markallread", "callee": "where", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L191"}, {"caller_nid": "notifications_markallread", "callee": "set", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L191"}, {"caller_nid": "notifications_markallread", "callee": "update", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L191"}, {"caller_nid": "notifications_markallread", "callee": "sql", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L193"}, {"caller_nid": "notifications_markallread", "callee": "and", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L195"}, {"caller_nid": "notifications_markallread", "callee": "eq", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L196"}, {"caller_nid": "notifications_markallread", "callee": "eq", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L197"}, {"caller_nid": "notifications_markallread", "callee": "isNull", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L198"}, {"caller_nid": "notifications_updateuserprefs", "callee": "trim", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L219"}, {"caller_nid": "notifications_updateuserprefs", "callee": "test", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L220"}, {"caller_nid": "notifications_updateuserprefs", "callee": "keys", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L225"}, {"caller_nid": "notifications_updateuserprefs", "callee": "where", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L226"}, {"caller_nid": "notifications_updateuserprefs", "callee": "set", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L226"}, {"caller_nid": "notifications_updateuserprefs", "callee": "update", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L226"}, {"caller_nid": "notifications_updateuserprefs", "callee": "eq", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L226"}, {"caller_nid": "notifications_getuserprefs", "callee": "limit", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L235"}, {"caller_nid": "notifications_getuserprefs", "callee": "where", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L235"}, {"caller_nid": "notifications_getuserprefs", "callee": "from", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L235"}, {"caller_nid": "notifications_getuserprefs", "callee": "select", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L235"}, {"caller_nid": "notifications_getuserprefs", "callee": "eq", "source_file": "src\\lib\\server\\services\\notifications.ts", "source_location": "L243"}]}