e0dd3f636896f439d9b9e65f4caa27c0fc66e206
Add submit_day_sheet, disapprove_day_sheet, justify_day_sheet,
approve_day_sheets (all SECURITY DEFINER, grant to authenticated)
and auto_submit_day_sheets (revoked from all client roles).
auto_submit_day_sheets:
1. Reopens approved yesterday sheets for programmers whose timer
was still running at end of day (amended event).
2. Auto-promotes stale draft sheets to pending (auto_submitted event).
3. Inserts day_sheet_digest notifications + scheduled_notifications
(epoch=YYYYMMDD, ON CONFLICT DO NOTHING) for every admin.
Extends chk_at_least_one_ref on scheduled_notifications to allow
notify_type = 'day_sheet_digest' rows with no FK reference.
Registers pg_cron job 'programmer_day_sheet_autosubmit' at 16:05 UTC
(00:05 Asia/Manila) in a DO $$ EXCEPTION block.
Co-Authored-By: claude-flow <ruv@ruv.net>
tasq
A new Flutter project.
Description
Languages
Dart
80.1%
JavaScript
5.8%
PLpgSQL
5.5%
Shell
3.4%
HTML
3%
Other
1.9%