updates_table.php: Fix identification of new packages

Currently, package creation has to be done separately from first
submission, so ModifiedTS will never be the same as SubmittedTS.
Consider all packages that are submitted within an hour from package
creation as new.

Signed-off-by: Marcel Korpel <marcel.korpel@gmail.com>
Signed-off-by: Lukas Fleischer <lfleischer@archlinux.org>
This commit is contained in:
Marcel Korpel 2015-08-19 09:47:10 +02:00 committed by Lukas Fleischer
parent e1f6de68a2
commit 57250a1641

View file

@ -10,7 +10,7 @@
<a href="<?= get_pkg_uri($row["Name"]); ?>" title="<?= htmlspecialchars($row["Name"]) . ' ' . htmlspecialchars($row["Version"]); ?>"><?= htmlspecialchars($row["Name"]) . ' ' . htmlspecialchars($row["Version"]); ?></a>
</td>
<td class="pkg-new">
<?php if ($row["ModifiedTS"] === $row["SubmittedTS"]): ?>
<?php if ($row["ModifiedTS"] - $row["SubmittedTS"] < 3600): ?>
<img src="images/new.png" alt="New!" />
<?php endif; ?>
</td>