-
Notifications
You must be signed in to change notification settings - Fork 15
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add video info view #1014
base: master
Are you sure you want to change the base?
Add video info view #1014
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, almost perfect!
While reviewing your code I found #1016 so if you feel like it, you could fix that here, too (but you don't have to 😉).
@@ -335,7 +340,7 @@ | |||
]); | |||
|
|||
// Legacy support. | |||
$router->redirect('videos/{id}', '/videos/{id}/annotations'); | |||
$router->redirect('video-annotate/{id}', '/videos/{id}/annotations'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This redirect doesn't make sense any more. I can be removed.
@if ($video->taken_at) | ||
<tr> | ||
<th>Created</th> | ||
@if (is_array($video->taken_at)) | ||
@foreach ($video->taken_at as $value) | ||
<td>{{ $value }}</td> | ||
@endforeach | ||
@else | ||
<td>{{ $video->taken_at }}</td> | ||
@endif | ||
</tr> | ||
@endif | ||
@foreach ($metadata as $key => $field) | ||
<tr> | ||
<th>{{ $metadataMap[$key] }}</th> | ||
@if (is_array($field)) | ||
@foreach ($field as $value) | ||
<td>{{ $value }}</td> | ||
@endforeach | ||
@else | ||
<td>{{ $value }}</td> | ||
@endif | ||
</tr> | ||
@endforeach |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Video metadata may be an array, too. This will produce an "array to string conversion" error here. How could we show these values here in a meaningful way? Maybe show the min/max values of each field only?
<div class="panel-heading"> | ||
<h3 class="panel-title">Video information</h3> | ||
</div> | ||
<div class="panel-body table-responsive"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No need to wrap this into a .panel-body
, this will only add an unnecessary padding around the table (see images/index/meta.blade.php).
As stated in Footprint / laser point detection for videos #70, we would like to add a new info view for videos, as for images, with metadata and, later, computed laser points info.