fix(capture): use duration_ms field for recent captures duration display
The asset schema stores duration as duration_ms (milliseconds). renderRecent() was checking c.duration (always undefined) so duration always showed as '—'. Fix to use c.duration_ms / 1000.
This commit is contained in:
parent
08e5ba6298
commit
ff892a1ad5
1 changed files with 2 additions and 2 deletions
|
|
@ -524,8 +524,8 @@
|
|||
<thead><tr><th>File</th><th>Duration</th><th>Date</th></tr></thead>
|
||||
<tbody>${captures.map(c => `
|
||||
<tr>
|
||||
<td class="truncate" style="max-width:200px">${esc(c.filename || c.clip_name || 'untitled')}</td>
|
||||
<td>${c.duration ? formatDuration(c.duration) : '—'}</td>
|
||||
<td class="truncate" style="max-width:200px">${esc(c.display_name || c.filename || 'untitled')}</td>
|
||||
<td>${c.duration_ms ? formatDuration(c.duration_ms / 1000) : '—'}</td>
|
||||
<td>${c.created_at ? new Date(c.created_at).toLocaleString() : '—'}</td>
|
||||
</tr>`).join('')}
|
||||
</tbody>
|
||||
|
|
|
|||
Loading…
Reference in a new issue