Repository navigation
Maintenance cycle and reminders - #31
Merged
Merged
Conversation
Recurrence on equipment, roll-forward when a maintenance work order is completed, overdue/upcoming maintenance and EPI expiry alerts on the dashboard, in notifications and in the daily job. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01StC4huMbM6BRB9r4XFXvXv
…ial update, isolate digest - rollMaintenanceForward only matches a work order due on the equipment's current next_maintenance, so re-opening/re-closing an old one cannot push the date forward again. - PUT equipment keeps the stored cycle when the field is absent. - Daily jobs: a failing admin digest no longer skips the status write. - Equipment form keeps a stored cycle that is not in the preset list. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01StC4huMbM6BRB9r4XFXvXv
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
equipment.maintenance_interval_monthscolumn (schema.js self-healing + init.sql) with API validation (1-120 months).last_maintenanceto today and movesnext_maintenanceforward by the interval. Done once per transition todone./api/dashboard/summary, shown on Home ("En retard / À venir" lists, dark-mode classes), turned into admin notifications by the daily job (de-duplicated over 7 days), and added to the admin email digest (only when email is configured).backend/test/maintenance-cycle.test.js; CHANGELOG "Non publié" entry.Test plan
node --test backend/test/*.test.jsagainst real Postgres (175 pass)npm run buildin frontendGenerated by Claude Code