mirror of
https://github.com/rickbarrette/redmine_qbo_vehicles.git
synced 2026-11-18 02:40:37 -05:00
The vehicle, edit and new vehicle pages' titles are a trail through the vehicle's customer (Vehicles » vehicle when it has none), and the vehicle page's actions sit under the title like the customer page's. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
13 lines
684 B
ERB
13 lines
684 B
ERB
<%= render partial: 'vehicles/trail', locals: { vehicle: @vehicle, tail: l(:label_new_vehicle) } %>
|
|
|
|
<%= labelled_form_for @vehicle do |f| %>
|
|
<%# Where to go back to, and what the vehicle is being added for (see VehiclesController#create) %>
|
|
<%= back_url_hidden_field_tag %>
|
|
<%= hidden_field_tag 'appointment_id', params[:appointment_id] if params[:appointment_id].present? %>
|
|
<%= render partial: 'vehicles/form', locals: { f: f } %>
|
|
<%= submit_tag l(:button_create) %>
|
|
<%= link_to l(:button_cancel), validate_back_url(params[:back_url].to_s) || (@vehicle.customer ? customer_path(@vehicle.customer) : vehicles_path) %>
|
|
<% end %>
|
|
|
|
<% html_title(l(:label_new_vehicle)) -%>
|