{
"s": true,
"d": [
{
"detailItemImage": []
},
{
"detailItemImage": []
},
{
"detailItemImage": [
{
"originalName": "puma_one.jpg",
"itemId": 101,
"path": null,
"rotate": 0,
"fileName": "/accurate/files/data_456811/item-image/item_101/item-image_9d07992d-663a-40d8-ba69-76e3aea874b2.jpg",
"extension": ".jpg",
"optLock": 0,
"thumbnailPath": "/accurate/files/data_456811/item-image/item_101/item-image-thumb_9d07992d-663a-40d8-ba69-76e3aea874b2.jpg",
"name": "img0",
"id": 50,
"seq": 0
}
]
},
{
"detailItemImage": []
}
],
"sp": {
"page": 1,
"sort": null,
"pageSize": 20,
"pageCount": 1,
"rowCount": 4,
"start": 0,
"limit": null
}
}
我有这样的代码,错误在哪里?
<tbody>
@php
$i = 1;
@endphp
@foreach ($data['d'] as $key => $item)
<tr class="odd">
<td>{{ $i++ }}</td>
@foreach ($data['d'['detailItemImage']] as $items)
<td>{{ $items['originalName']}}</td>
<td>
<div class="btn-group">
<a href="{{ url('detail-produk/'.$key)}}"
class="btn btn-success btn-sm">Detail</a>
<a href="" {{--"{{ url('edit-kat/'.$key)}}" --}}
class="btn btn-warning btn-sm">Edit</a>
<a href="" {{--"{{ url('edit-kat/'.$key)}}" --}}
class="btn btn-danger btn-sm">Hapus</a>
</div>
</td>
@endforeach
</tr>
@endforeach
</tbody>