Skip to content

Commit e04f699

Browse files
authored
[Feature] Added packet loss to form view and table (alexjustesen#1300)
1 parent 5e1b807 commit e04f699

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

app/Filament/Resources/ResultResource.php

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,8 @@ public static function form(Form $form): Form
7474
->label('Upload Jitter (ms)'),
7575
Forms\Components\TextInput::make('data.ping.jitter')
7676
->label('Ping Jitter (ms)'),
77+
Forms\Components\TextInput::make('data.packetLoss')
78+
->label('Packet Loss'),
7779
Forms\Components\Textarea::make('data.message')
7880
->label('Error Message')
7981
->hint(new HtmlString('&#x1f517;<a href="https://docs.speedtest-tracker.dev/help/error-messages" target="_blank" rel="nofollow">Error Messages</a>'))
@@ -163,6 +165,9 @@ public static function table(Table $table): Table
163165
->sortable(query: function (Builder $query, string $direction): Builder {
164166
return $query->orderBy('data->ping->jitter', $direction);
165167
}),
168+
Tables\Columns\TextColumn::make('packet_loss')
169+
->toggleable()
170+
->toggledHiddenByDefault(),
166171
Tables\Columns\TextColumn::make('status')
167172
->toggleable()
168173
->sortable(),

0 commit comments

Comments
 (0)