fix: 流程明细分页变量避开布局冲突 #619
@ -30,7 +30,7 @@ class ProcessDetails extends Controller
|
||||
return view('business.pages.financial-operations.process-details', [
|
||||
'section' => ['slug' => 'financial-operations', 'title' => '财务经营报表'],
|
||||
'page' => ['slug' => 'process-details', 'title' => '流程明细'],
|
||||
'rows' => new LengthAwarePaginator(
|
||||
'processRows' => new LengthAwarePaginator(
|
||||
$result['data'],
|
||||
$result['total'],
|
||||
$perPage,
|
||||
@ -53,7 +53,7 @@ class ProcessDetails extends Controller
|
||||
return view('business.pages.financial-operations.process-details', [
|
||||
'section' => ['slug' => 'financial-operations', 'title' => '财务经营报表'],
|
||||
'page' => ['slug' => 'process-details', 'title' => '流程明细'],
|
||||
'rows' => new LengthAwarePaginator([], 0, $perPage, $page, [
|
||||
'processRows' => new LengthAwarePaginator([], 0, $perPage, $page, [
|
||||
'path' => $request->url(),
|
||||
'query' => $request->except('page'),
|
||||
]),
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
@php
|
||||
$rows = $rows ?? null;
|
||||
$processRows = $processRows ?? null;
|
||||
$filters = $filters ?? [];
|
||||
$summary = $summary ?? [];
|
||||
$months = $months ?? [];
|
||||
@ -414,9 +414,9 @@
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
@forelse ($rows as $row)
|
||||
@forelse ($processRows as $row)
|
||||
<tr>
|
||||
<td class="num">{{ ($rows->currentPage() - 1) * $rows->perPage() + $loop->iteration }}</td>
|
||||
<td class="num">{{ ($processRows->currentPage() - 1) * $processRows->perPage() + $loop->iteration }}</td>
|
||||
<td>{{ $row->business_id }}</td>
|
||||
<td>{{ $text($row->originator_name) }}</td>
|
||||
<td class="center">
|
||||
@ -447,9 +447,9 @@
|
||||
|
||||
<div class="process-details-footer">
|
||||
<span>
|
||||
第 {{ $rows->currentPage() }} / {{ max($rows->lastPage(), 1) }} 页,共 {{ number_format($rows->total()) }} 行
|
||||
第 {{ $processRows->currentPage() }} / {{ max($processRows->lastPage(), 1) }} 页,共 {{ number_format($processRows->total()) }} 行
|
||||
</span>
|
||||
<div>{{ $rows->links() }}</div>
|
||||
<div>{{ $processRows->links() }}</div>
|
||||
</div>
|
||||
</div>
|
||||
</x-slot>
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user