• Mahmoud Aglan's avatar
    fix: writes that named columns the database does not have · 952e2ce6
    Mahmoud Aglan authored
    Every one of these was rejected by PostgREST and reported as success
    (found by checking each insert/update/select against the live schema):
    
    - workflows: approval_requests has reviewed_by/review_notes, not
      reviewer_id/review_note; reviewers and requesters are staff uuids, so the
      pages now show their names, "my requests" filters by the account id, and
      search no longer runs ilike on a uuid. workflow_rules has event_type, not
      event; created_by is a uuid; conditions/actions go in as jsonb lists.
    - RuleEngine: event_type, and its notify action writes a real notifications
      row (user_id, title_ar/body_ar) only when addressed to a player.
    - moderation: cheat_reports.reviewed_by references profiles, so a staff
      reviewer is stored in the new reviewed_by_admin column.
    - users: admin_users has no created_by.
    - org-transfers, org-frames, org-chat: org_members has player_id (not
      user_id) and no status column. Membership logic is unchanged.
    - org-achievements: an org achievement cannot be stored in
      player_achievements (its achievement_id references the game's
      achievements); granting now says so instead of failing the insert and
      still paying the reward. Progress reads completed/completed_at.
    - org-loyalty, org-partnerships: those tables have no updated_at.
    - live pages: phases are in tournament_phases ordered by phase_number; the
      arena tables never existed.
    Co-Authored-By: 's avatarClaude Opus 5.5 <noreply@anthropic.com>
    952e2ce6
Name
Last commit
Last update
..
ads Loading commit data...
analytics Loading commit data...
audit-log Loading commit data...
auth/views Loading commit data...
branding Loading commit data...
chess-bots Loading commit data...
dashboard Loading commit data...
economy Loading commit data...
feature-flags Loading commit data...
games Loading commit data...
live-tournaments Loading commit data...
moderation Loading commit data...
notifications Loading commit data...
org-achievements Loading commit data...
org-announcements Loading commit data...
org-applications Loading commit data...
org-challenges Loading commit data...
org-chat Loading commit data...
org-content Loading commit data...
org-events Loading commit data...
org-frames Loading commit data...
org-invites Loading commit data...
org-leaderboards Loading commit data...
org-loyalty Loading commit data...
org-media Loading commit data...
org-partnerships Loading commit data...
org-recruitment Loading commit data...
org-rosters Loading commit data...
org-spotlights Loading commit data...
org-training Loading commit data...
org-transfers Loading commit data...
org-treasury Loading commit data...
organizations Loading commit data...
players Loading commit data...
settings Loading commit data...
tournaments Loading commit data...
users Loading commit data...
workflows Loading commit data...