diff --git a/app/Http/Controllers/OpsController.php b/app/Http/Controllers/OpsController.php index d2b49e1..94dc817 100644 --- a/app/Http/Controllers/OpsController.php +++ b/app/Http/Controllers/OpsController.php @@ -182,23 +182,19 @@ class OpsController extends Controller */ private function getAvailableActions(Order $order): array { - $actions = []; - - match ($order->status) { + return match ($order->status) { 'inspection' => [ - $actions['markInspectionPassed'] = true, - $actions['flagInspectionIssue'] = true, + 'markInspectionPassed' => true, + 'flagInspectionIssue' => true, ], 'packing' => [ - $actions['confirmPacking'] = true, + 'confirmPacking' => true, ], 'ready_to_ship', 'awaiting_collection', 'in_transit' => [ - $actions['readOnly'] = true, + 'readOnly' => true, ], default => [] }; - - return $actions; } /** diff --git a/storage/framework/views/3eb3669279660d3820de15e6e8eeb5d9.php b/storage/framework/views/3eb3669279660d3820de15e6e8eeb5d9.php new file mode 100644 index 0000000..5cca5de --- /dev/null +++ b/storage/framework/views/3eb3669279660d3820de15e6e8eeb5d9.php @@ -0,0 +1,141 @@ + + +startSection('content'); ?> +
uuid); ?>
+Status
+status)); ?>
+Order Type
+is_custom_order ? 'Custom' : 'Standard'); ?>
+Customer
+user->name ?? 'N/A'); ?>
+Created
+created_at->format('M d, Y')); ?>
+Scan to access this order:
+No actions available for this order status.
+| Product | +Type | +Quantity | +Amount | +
|---|---|---|---|
| product->name ?? 'N/A'); ?> | +product_type ?? 'N/A'); ?> | +quantity); ?> | +Runit_price * $item->quantity, 2)); ?> | +
| No items | +|||
Width
+packing_width); ?> cm
+Length
+packing_length); ?> cm
+Weight
+packing_weight); ?> kg
+Packed At
+packing_completed_at->format('M d, H:i')); ?>
+Waybill ID
+courier_waybill_id); ?>
+Tracking Number
+courier_tracking_number ?? 'N/A'); ?>
+Status
+courier_status ?? 'pending')); ?>
+