mirror of
https://github.com/rickbarrette/redmine_qbo_vehicles.git
synced 2026-11-18 02:40:37 -05:00
Add Vehicle from an appointment sets it there and returns
The appointment page's Add Vehicle link (shown when the appointment has none) now carries the appointment and a back_url. Creating the vehicle calls a new :controller_vehicles_new_after_save hook; this plugin's listener sets the vehicle on that appointment (same customer, no vehicle yet, user may edit appointments) and the form redirects back to the appointment. The calendar plugin is unchanged. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01BiwYMjhoQvL7XsKKfRz4pM
This commit is contained in:
7 files changed
+57
-6
No files matched your search
@@ -23,7 +23,8 @@ The goal of this project is to enable vehicle tracking for customer vehicles wit
|
||||
* **Invoices (redmine_qbo 2026.11.2+):** importing a work order's time or estimate fills the invoice's VIN box with its vehicle's VIN and the mileage box with the highest value of the work orders' **Mileage** issue custom field (Redmine's own custom field named "Mileage"), and an invoice whose work orders are for more than one vehicle isn't saved (one vehicle per invoice).
|
||||
* **Estimates (redmine_qbo 2026.11.2+):** the VIN box suggests the customer's vehicles, an invoice made from an estimate without a VIN gets its work orders' vehicle, and the Create issues from estimate page has a **Vehicle** for all the issues: preselected with the appointment's vehicle, or else the customer's vehicle whose VIN is on the estimate; when none matches it says so, so the team can pick one before creating the issues.
|
||||
* **Customer page:** ticking a vehicle adds it to the New issue link.
|
||||
* **Appointments (redmine_qbo_calendar):** an appointment added from an estimate gets the customer's vehicle with the estimate's VIN.
|
||||
* **Appointments (redmine_qbo_calendar):** an appointment added from an estimate gets the customer's vehicle with the estimate's VIN. On an appointment without a vehicle, **Add Vehicle** creates one for the customer, sets it on the appointment and returns to it (for users who may edit appointments).
|
||||
* **For other plugins:** creating a vehicle calls the `:controller_vehicles_new_after_save` hook (context: `params`, `vehicle`), and the new vehicle form returns to `back_url` when given, so a plugin can link to `new_vehicle_path(customer_id:, back_url:, ...)` and act on the vehicle it gets back.
|
||||
|
||||
## Installation
|
||||
|
||||
|
||||
Reference in new issue
Block a user