release: Fleet-Ops v0.6.65 - #318
Merged
Merged
Conversation
Public API - Adopt the public relation contract: category_id, vendor_id, warranty_id, photo_id and vehicle_id are always present; category, vendor, warranty, photo and positions expand through with/expand like Vehicles. - Strip device and event UUIDs from the public telematics snapshot. - Return 409 responses instead of aborting inside transactions for towing conflicts; resolve vehicles by public or internal id; fall back to the container request in find(); ignore null-island track observations. - Expose towing connections with vehicle_id/trailer_id identifiers and full models for the console. - Expose currently attached trailers on Vehicles via with=trailers. Internal API - Consistent error responses, delete guard for attached trailers (single and bulk), statuses/types endpoints for console filters, resource-wrapped attach/detach responses, and vehicle attach/detach equipment endpoints. - Console filters submit arrays and UUIDs: TrailerFilter accepts both and resolves vehicle/vendor/category identifiers; EquipmentFilter::equipable resolves the asset instead of whereHas() on a morphTo relation, which silently matched nothing. - Always embed connections/devices/equipments for the console so Ember Data stops warning about missing embedded relationships. - Share status/type/ownership constants between validation, import and the model; make the test fixtures re-boot models after replacing the event dispatcher so hooks survive cross-file runs.
- Rebuild the trailer form with grouped sections, localized labels, placeholders and help text, unit-aware dimension/weight/temperature fields driven by the measurement system, select controls for type, status, coupling, brakes, ownership and odometer unit, money/date/currency inputs, and conditional reefer and lease sections. - Rebuild the details overview (identity, towing connection with attach/ detach, telematics, dimensions, running gear, refrigeration, ownership, notes/timestamps) and add dedicated Towing history, Equipment, Schedules, Work orders and Maintenance tabs with tables, empty states and actions. - Rebuild the index with localized enum cells (new cell/translated-value), towing vehicle link, multi-option/date/model filters mapped to backend params, bulk delete, and strip empty query params before querying. - Rework trailer-actions (panel/modal APIs, attach/detach vehicle with towing position, device and equipment attach/detach with confirmations, locate, maintenance shortcuts) and add attach trailer/equipment actions to vehicle-actions with matching Vehicle detail tabs. - Make Device::Manager target the resource's own endpoint so trailer device attachment no longer posts to the vehicle route. - Add the missing app/ re-exports for trailer components, controllers, routes and templates; modal components no longer import a non-existent ember-core base. - Localize every trailer string in all nine locales (translated, with placeholder parity), plus vehicle attach-trailer/equipment strings.
…ole flows - Assert the rendered Resources menu places Trailers directly after Vehicles (stubbing the console-only universe services the dummy app lacks) instead of inspecting component source. - Cover store.query/queryRecord normalization of the trailers/trailer envelopes, including the empty collection. - Cover trailer-actions defaults, panel tabs, and the attach/detach requests; the details controller tabs and attach/detach actions; the index route query params against the controller columns; the trailer form's placeholders, unit labels and conditional sections; and the translated-value cell. - Provide an inert stand-in for the console extensions module so the dummy app can boot the universe services.
…elds The public resource contract test inspects the resource source for $this->when(Http::isInternalRequest(), ...) on every uuid-bearing field; caching the check in a local broke that inspection.
- Style the attached/detached, in-use, out-of-service and retired badges, which ember-ui's palette does not define. - Rebuild the trailer card body as an image stage plus a padded summary strip (status, connectivity, towing vehicle link) instead of badges on the raw body. - Make the details tab content the scroll container (tab-navigation-fill) so the last overview sections are reachable; apply the same to Vehicles. - Give route-backed detail tabs stable ids so TabNavigation can compute its More menu instead of clipping the trailing tabs. - Introduce a shared AttachmentList component plus Equipment and Trailer pills, and use them for the devices, equipment, vehicle trailers and towing history tabs so they share one header, row and empty-state structure. Towing history becomes a compact timeline rather than a seven-column table. - Ship an inline trailer placeholder image (overridable through defaultValues.trailerImage) instead of falling back to the vehicle photo. - Translate the new strings in all locales; add attachment-list and placeholder tests.
The live vehicles feed eager-loads each vehicle's current trailers next to its devices, and the index resource emits a compact trailers list. Both map providers render Trailers and Devices cells with an online dot per row: the Leaflet marker popup/tooltip templates and the Google info-window builder, which escapes names before injecting them as HTML. Covered by resource, live endpoint and popover-builder tests.
Share one asset-card structure between vehicles and trailers: an image stage with the resource placeholder, a padded summary strip with status and online/offline badges plus the assigned-driver link (or the no-driver state), and footer actions with tooltips and permissions. Adds the common.offline and vehicle.fields.updated-at strings the card uses in every locale.
Cards now share one structure: a title row with the online indicator, an image body on the card background, and a footer with the status badge beside the actions followed by meta rows that style linked records the same way. The vehicle card lists the assigned driver and the trailers it is towing; the trailer card lists the towing vehicle and connectivity; the driver card links its assigned vehicle. The internal vehicle payload carries a compact list of current trailers (shared TrailerSummary helper, also used by the live map resource) and the vehicles index requests it. Adds the shared common strings in every locale.
Adds the table/grid layout switch (remembered per listing) and card components for vendors and contacts, reusing the shared resource-card structure. Customers reuse the contact card through the customer actions service.
The repository ignores `vendor` directories for Composer output, which also hid the new Vendor::Card files from the grid-view commit.
The driver badge rendered its raw status value through the block form, which skips the badge's humanizer. Vehicle and trailer images now cover the body like the driver photo instead of sitting padded inside it.
Attaching a device that is already installed on another vehicle or trailer silently moved it, so an operator could take a tracker off one asset with no feedback (fleetops#177). Device::attachTo now throws DeviceAlreadyAttachedException and every attach endpoint (internal device, vehicle and trailer controllers, public device API) answers 409 with the asset the device is still attached to. Re-attaching to the same asset stays idempotent.
Vehicles: filter by one or more drivers, trailers or devices (new filter/multi-model component over ModelSelectMultiple), by whether a trailer, driver or device is attached (with the inverse), and by several internal ids at once; the vendor placeholder resolves through the common namespace. Trailers: filter by devices; the refrigerated checkbox drops its redundant group label and moves to the end of the panel. Orders: the internal id filter is a tag input so a batch of scanned or pasted ids matches in one query (fleetbase#576). Backend filters accept the comma-separated lists and relation presence flags, with contract tests.
The small form-input height capped the multiple-select trigger at 34px with an internal scroller, so the placeholder was clipped before anything was chosen. The trigger now starts at the input height, wraps its chips and grows with them.
Extends the inline trailer placeholder into a matching set for vehicles, drivers, fleets, vendors, contacts and customers, exposed through placeholder-image and resource-image helpers. resource-image treats a blank photo or one of the legacy hosted defaults (no-avatar, vehicle-placeholder, image-file-icon) as "no photo" so the styled silhouette shows instead. Cards and panel headers use it; the vendor card image now fills the body like the others, and the vehicle header no longer falls back to the driver avatar. Consoles can override any silhouette via defaultValues.placeholders.<type>.
Completes the previous commit, which only removed the old trailer placeholder test: adds the placeholder-images util with inline SVG silhouettes for vehicles, drivers, fleets, vendors, contacts and customers, the placeholder-image and resource-image helpers (a blank photo or a legacy hosted default resolves to the styled silhouette; consoles can override each via defaultValues.placeholders.<type>), and uses them in the cards and panel headers. The vendor card image now fills the body and the vehicle header no longer falls back to the driver avatar.
The first driver cap read as a bandana: a shallow dome with a band and a stray side flap. The cap is now a full crown with a centre seam and button and a side bill, which reads as a cap at card size.
…e shows Forms, modals, pills, table cells, fleet listings, order cards and overlays, the orchestrator panel and the connectivity views now resolve driver, vehicle, trailer, vendor, contact and customer images through resource-image, so the hosted no-avatar and vehicle PNGs no longer appear anywhere in the engine. getPlaceholderImage also honours a console whose defaultValues.<type>Image is already an inline data URI, so a console-level swap of the defaults takes precedence over the engine's built-in set.
Add first-class Trailer operations
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #318 +/- ##
=============================================
Coverage 100.00% 100.00%
- Complexity 10007 10274 +267
=============================================
Files 531 545 +14
Lines 38592 39684 +1092
=============================================
+ Hits 38592 39684 +1092
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
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
Planned release work
PR #309 will target this release branch for review before the release is merged to
main.Verification