mirror of
https://github.com/lrnselfreliance/wrolpi.git
synced 2026-10-26 19:01:39 -04:00
Showing 'now' when next_download time has been passed.
This commit is contained in:
parent
9d9167c5ec
commit
c24353edf2
1 changed files with 9 additions and 1 deletions
|
|
@ -155,6 +155,14 @@ class DownloadRow extends React.Component {
|
|||
/>
|
||||
</>;
|
||||
|
||||
// Show "now" if we have passed the next_download.
|
||||
let next = 'now';
|
||||
if (next_download) {
|
||||
if (new Date() < new Date(next_download)) {
|
||||
next = isoDatetimeToElapsedPopup(next_download);
|
||||
}
|
||||
}
|
||||
|
||||
return <TableRow>
|
||||
<TableCell>
|
||||
{link(textEllipsis(url, 50))}
|
||||
|
|
@ -164,7 +172,7 @@ class DownloadRow extends React.Component {
|
|||
{last_successful_download ? isoDatetimeToElapsedPopup(last_successful_download) : null}
|
||||
{status === 'pending' ? <Loader active inline size='tiny'/> : null}
|
||||
</TableCell>
|
||||
<TableCell>{next_download ? isoDatetimeToElapsedPopup(next_download) : null}</TableCell>
|
||||
<TableCell>{next}</TableCell>
|
||||
<TableCell>
|
||||
{error && errorModal}
|
||||
{deleteButton}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue