Skip to content

LIMS-2022: Don't hide shipment buttons#1025

Merged
ndg63276 merged 1 commit intopre-release/2026-R1.3from
improvement/LIMS-2022/dont-hide-shipment-buttons
Feb 3, 2026
Merged

LIMS-2022: Don't hide shipment buttons#1025
ndg63276 merged 1 commit intopre-release/2026-R1.3from
improvement/LIMS-2022/dont-hide-shipment-buttons

Conversation

@ndg63276
Copy link
Collaborator

JIRA ticket: LIMS-2022

Summary:

If a shipment doesn't have a lab contact or a safety level, currently the "Create Air Way Bill" and "Print Shipment Labels" buttons are hidden. They should be displayed, and show an error when clicked to say why they are disabled.

Changes:

  • Update the shipment model to reflect that safety level is required, while return lab contact is optional. Add human readable messages.
  • Remove the logic that hides the buttons
  • Add functions to the Create AWB and Print Labels buttons, so they validate the model, and either display the error or continue to the relevant URL
  • Update the message at the top of the page to cope with the shipping service being enabled, and to not hard code the required fields

To test:

  • View a shipment with no Outgoing Lab Contact or Safety Level (or set to null, or upload a CSV to create one)
  • Click "Print Shipment Labels" or "Create DHL Air Waybill" check an error message appears
  • Check "Print Contents" and "Mark as Sent" work anyway (and status changes to "sent to facility")
  • Fix the problem(s), check the "Print Shipment Labels" and "Create DHL Air Waybill" buttons now work
  • If $use_shipping_service_redirect_incoming_shipments is not set to True, set it to True and go through the process using the shipping service (on a new shipment if needed).
  • Check the button now changes to "Manage Shipment Booking" and the green text at the top reflects this.

@ndg63276 ndg63276 changed the base branch from master to pre-release/2026-R1.3 February 3, 2026 09:47
@ndg63276 ndg63276 merged commit 034b244 into pre-release/2026-R1.3 Feb 3, 2026
2 checks passed
@ndg63276 ndg63276 deleted the improvement/LIMS-2022/dont-hide-shipment-buttons branch February 3, 2026 09:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants