1. 12 May, 2026 1 commit
    • feat(backend): submissions module + scope filter + compression · 8a959f9b
      - Submissions module (routes/repository/service/types/domain) with
        draft → submitted state machine, transition endpoint, Azure SAS
        file attachment via blob-storage service, conduct score, and
        org-scope filters (orgId/companyId/countryId/entityId/buId/deptId/areaId).
      - Forms: GET /api/forms/by-scope alias + scope filter on listForms
        (empty-array OR id-in-array semantics); GET /api/forms/managers
        joining auth.users + user_org_assignment with active-user fallback.
      - Form settings: persist frequencyCycle, visibility, country/sub/
        company/entity/BU scope arrays, role arrays via buildSettings
        assignments. Checksum no-op skips full survey_json TOAST rewrite
        on draft PATCH when checksum matches.
      - Performance: register @fastify/compress (br/gzip/deflate, 1 KiB
        threshold) — large surveyJson GETs drop 85–98% on the wire. Body
        limit bumped to 16 MB so PATCH/POST of full form schemas no longer
        trips 413 (which the browser was surfacing as CORS errors).
      - CORS: explicit allowedHeaders (incl. if-match/etag, x-tenant-id,
        x-confirm-delete-all), expose etag, credentials, 10 min preflight
        cache.
      - Migrations 004_form_settings + 005_seed_test_forms and a
        scripts/migrate-webforms helper for legacy form import.
      krds-arun authored
  2. 08 May, 2026 1 commit
  3. 06 May, 2026 3 commits