HT Vehicle Analytic
This module extends Fleet and Inventory to support analytic accounting on vehicles / trailers when delivering spare parts.
Features
Adds "Sequence Prefix" and "Apply Sequence" to Vehicle Model Category (fleet.vehicle.model.category).
New model "Trailer" (fleet.trailer) whose reference (name) is auto-generated from a per-category sequence when the selected category has "Apply Sequence" enabled.
Adds an Analytic Account field on Vehicles and Trailers, plus a bidirectional Vehicle <-> Trailer link (settable from either side) and a Category-based domain/default when linking/creating a Trailer from the Vehicle form.
Adds a "Spare Parts Delivery" checkbox on Operation Types (stock.picking.type). Only deliveries using such an operation type show the "Apply On" (Vehicle / Trailer / Both) radio and the related Vehicle / Trailer fields.
When the delivery is validated, the stock valuation journal entry generated for the move(s) gets an analytic distribution built from the vehicle/trailer analytic account(s), applied ONLY on the expense side of the entry (debit for a delivery, credit for a return, since a return reverses the original entry):
- Vehicle only -> 100% on the vehicle's analytic account.
- Trailer only -> 100% on the trailer's analytic account.
- Both, same analytic plan -> 50% / 50% split between the two.
- Both, different analytic plans -> 100% / 100% (one distribution key combining both accounts, since they sit on different, independent analytic axes/plans).
Returns created from a spare-parts delivery automatically inherit its Apply On / Vehicle / Trailer so the reversal entry is allocated consistently.
Non-blocking warning (banner + chatter note) when the selected Vehicle/Trailer has no Analytic Account configured; a hard validation still requires the Vehicle/Trailer field itself to be filled in when "Apply On" needs it.
Multi-company aware domains on Vehicle/Trailer selection, and smart buttons on the Vehicle and Trailer forms showing their linked deliveries.
Please log in to comment on this module