@extends('layouts.app') @section('title', 'Quality Control') @section('content')

Quality Control Inspections

New Inspection
@forelse($qualityChecks as $check) @empty @endforelse
Product Reference Quantity Good/Bad Inspector Status Date
{{ $check->product->name }}
{{ $check->product->sku }}
@if($check->workOrder) {{ $check->workOrder->order_number }} @else Direct Check @endif
{{ number_format($check->passed_quantity, 0) }} ok {{ number_format($check->failed_quantity, 0) }} reject
@php $perc = ($check->checked_quantity > 0) ? ($check->passed_quantity / $check->checked_quantity) * 100 : 0; @endphp
{{ $check->inspector->name }}
@php $class = [ 'pass' => 'success', 'fail' => 'danger', 'conditional_pass' => 'warning' ][$check->status] ?? 'secondary'; @endphp {{ $check->status }}
{{ $check->created_at->format('M d, Y') }}
{{ $check->created_at->format('H:i') }}
No quality inspections recorded yet.
@if($qualityChecks->hasPages()) @endif
@endsection