Uses redmine_qbo's new :view_customers_show_contextual hook (replacing
customer_actions_top) and renders "Add appointment" as a Redmine-style
icon link alongside the customer's other actions. Needs the matching
redmine_qbo update.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01BiwYMjhoQvL7XsKKfRz4pM
The last line ended in a lone \r with no newline (left over from
restoring the file's CRLF line endings), so Ruby warned 'encountered \r
in middle of line' at every start. It now ends with CRLF like the rest.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01BiwYMjhoQvL7XsKKfRz4pM
Redmine has no default-project setting for new issues, so the preview
page used the first project the user could add issues to whenever an
appointment had no project. The plugin settings now have a Default
project; the order is: project chosen on the page, the appointment's
project, the default project, then the first allowed project.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01BiwYMjhoQvL7XsKKfRz4pM
- New issues from the estimate preview are now related to each other
and to every issue created earlier from the same estimate; older
batches that weren't related to each other are linked too
- Pairs that already have any relation are skipped
- New rake task redmine_qbo_calendar:relate_estimate_issues relates
issues created before this change (safe to re-run)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01BiwYMjhoQvL7XsKKfRz4pM
Every issue created in one batch from the estimate preview is now
related ("Related to") to every other issue in that batch. Relations
are added without journals, so no history entries or update emails
are generated; a relation that fails is logged and doesn't block
issue creation.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01BiwYMjhoQvL7XsKKfRz4pM
- New "Issue fields" section on the Create Issues from Estimate page
lists the custom fields the selected trackers use; values are entered
once and applied to every created issue whose tracker uses the field
- Required fields (the field's Required flag or a workflow rule for the
tracker and the user's role) are starred; the list updates as lines
are ticked or trackers change
- Values go through Issue#safe_attributes=, so fields that are hidden or
read-only for the user, or unused by a tracker, are ignored
- Entered values are kept when creation fails validation
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01BiwYMjhoQvL7XsKKfRz4pM
- "Create Issues from Estimate" now opens a preview listing each
matching estimate line: include checkbox, subject (from the line
description), tracker dropdown, template dropdown and estimated
hours (from the line quantity)
- Admins set which QBO item codes to look for (e.g. Labor, Alignments)
and a default tracker in the plugin settings
- Optional redmine_issue_templates support: templates supply the issue
description; titles still come from the line description
- New appointment_estimate_issues table records which issue came from
which estimate line, so a line can't be turned into an issue twice;
deleting the issue frees the line again
- Creation is all-or-nothing; errors are shown on the preview page
- Removes the old Labor-only create_issues_from_labor_lines code
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01BiwYMjhoQvL7XsKKfRz4pM
- customer_options is now covered by the add/edit permissions, so
non-admin staff get the vehicle/estimate dropdowns
- create_issues is now a POST member route with its own permission,
checks add_issues on the target project, no longer redirects to a
missing route, and has a button on the appointment page
- "Last" week-of-month holidays (e.g. Memorial Day) now match every year
- Cancelled and Call Out appointments no longer count toward hours
- Calendar only shows appointments to users with View customer
appointments, and only loads those near the displayed month
- due_date skips weekends and holidays, matching the calendar layout
- Subjects keep their casing; only the first letter is capitalized
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01BiwYMjhoQvL7XsKKfRz4pM
- Customer page list now shows a History link and a 'View all N past
appointments' link; it also renders when a customer has history but
nothing upcoming
- Calendar toolbar gets an Appointment History button
- Calendar tooltip gets a history icon next to the customer
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01BiwYMjhoQvL7XsKKfRz4pM
- Implement customer ID assignment in the appointment creation process.
- Create a new partial for customer actions to render appointment links.
- Add localization for the "Add Appointment" label.
- Introduce CustomerActionsHookListener to manage customer actions rendering.