feat: 日志统计人数可查看明细
This commit is contained in:
parent
5eea1c440b
commit
ec2f294fb7
@ -319,20 +319,25 @@
|
||||
@php
|
||||
$isSelected = $worklogFilters['date'] === $day['statistics_date'];
|
||||
$deadline = \Illuminate\Support\Carbon::parse($day['statistics_date'])->addDay()->setTime(12, 0);
|
||||
$detailUrl = route('business.pages.show', [
|
||||
'section' => 'other',
|
||||
'page' => 'log-statistics',
|
||||
'from' => $worklogFilters['from'],
|
||||
'to' => $worklogFilters['to'],
|
||||
'date' => $day['statistics_date'],
|
||||
]) . '#worklog-detail';
|
||||
@endphp
|
||||
<tr @class(['is-selected' => $isSelected])>
|
||||
<td>
|
||||
<a href="{{ route('business.pages.show', [
|
||||
'section' => 'other',
|
||||
'page' => 'log-statistics',
|
||||
'from' => $worklogFilters['from'],
|
||||
'to' => $worklogFilters['to'],
|
||||
'date' => $day['statistics_date'],
|
||||
]) }}">{{ $day['statistics_date'] }}</a>
|
||||
<a href="{{ $detailUrl }}">{{ $day['statistics_date'] }}</a>
|
||||
</td>
|
||||
<td>{{ $deadline->format('Y-m-d H:i:s') }}</td>
|
||||
<td class="is-number">{{ number_format((int) $day['submitter_count']) }}</td>
|
||||
<td class="is-number">{{ number_format((int) $day['submission_count']) }}</td>
|
||||
<td class="is-number">
|
||||
<a href="{{ $detailUrl }}" title="查看 {{ $day['statistics_date'] }} 提交人姓名">{{ number_format((int) $day['submitter_count']) }}</a>
|
||||
</td>
|
||||
<td class="is-number">
|
||||
<a href="{{ $detailUrl }}" title="查看 {{ $day['statistics_date'] }} 日志明细">{{ number_format((int) $day['submission_count']) }}</a>
|
||||
</td>
|
||||
<td>{{ $day['first_submitted_at'] ?: '-' }}</td>
|
||||
<td>{{ $day['last_submitted_at'] ?: '-' }}</td>
|
||||
</tr>
|
||||
@ -343,7 +348,7 @@
|
||||
@endif
|
||||
</section>
|
||||
|
||||
<section class="log-statistics-panel" aria-label="日志提交明细">
|
||||
<section id="worklog-detail" class="log-statistics-panel" aria-label="日志提交明细">
|
||||
<div class="log-statistics-panel__head">
|
||||
<strong>日志提交明细</strong>
|
||||
<span>{{ $worklogFilters['date'] }}</span>
|
||||
|
||||
@ -146,7 +146,10 @@ class PagesTest extends FeatureTestCase
|
||||
->assertSeeText('2026-11-03')
|
||||
->assertSeeText('秋香')
|
||||
->assertSeeText('李斯')
|
||||
->assertSeeText('2026-11-04 10:26:00');
|
||||
->assertSeeText('2026-11-04 10:26:00')
|
||||
->assertSee('id="worklog-detail"', false)
|
||||
->assertSee('title="查看 2026-11-03 提交人姓名"', false)
|
||||
->assertSee('title="查看 2026-11-03 日志明细"', false);
|
||||
} finally {
|
||||
Carbon::setTestNow();
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user