@extends('layouts.demo10.base') @php $approvalCount = count($data ?? []); $approvalChangeDetails = collect($data ?? [])->mapWithKeys(function ($item) { $change = $item['changes'] ?? []; $instanceId = $item['step']->workflow_instance_id ?? ''; $rowUuid = $change['row_uuid'] ?? ''; $detailKey = $instanceId . '_' . $rowUuid; return [ $detailKey => [ 'workflow_instance_id' => $instanceId, 'row_uuid' => $rowUuid, 'table_name' => $change['table_name'] ?? 'submissions', 'row_key' => $change['row_key'] ?? '__id', 'column_labels' => $change['column_labels'] ?? [], 'old_data' => $change['old_data'] ?? [], 'new_data' => $change['new_data'] ?? [], ], ]; }); @endphp @section('content')
| UUID | {{-- @if(count($data) > 0) @foreach(array_keys((array) $data[0]['submission']) as $col){{ $col }} | @endforeach @endif --}}Actions |
|---|---|---|
| {{ $rowUuid }} | {{-- @foreach($submission as $col => $value) @php $updatedValue = $changes[$col] ?? $value; $highlight = array_key_exists($col, $changes) ? 'approval-cell-updated' : ''; $displayValue = filled((string) $updatedValue) ? $updatedValue : '-'; @endphp{{ $displayValue }} | @endforeach --}}