kopia lustrzana https://github.com/magicbug/Cloudlog
Show last LoTW upload as visual hint
rodzic
bab2e1d589
commit
2994012543
|
@ -99,7 +99,18 @@ function echoQrbCalcLink($mygrid, $grid, $vucc) {
|
|||
<?php } ?>
|
||||
<td>
|
||||
<a id="edit_qso" href="javascript:displayQso(<?php echo $row->COL_PRIMARY_KEY; ?>)"><?php echo str_replace("0","Ø",strtoupper($row->COL_CALL)); ?></a>
|
||||
<?php $timestamp = strtotime($row->lastupload); echo ($row->callsign == '' ? '' : ' <small id="lotw_info" class="badge badge-success" data-toggle="tooltip" data-original-title="LoTW User. Last upload was '.date($custom_date_format." H:i", $timestamp).'">L</small>'); ?>
|
||||
<?php
|
||||
$lotw_hint = '';
|
||||
$diff = (time() - strtotime($row->lastupload)) / 86400;
|
||||
if ($diff > 365) {
|
||||
$lotw_hint = ' lotw_info_red';
|
||||
} elseif ($diff > 30) {
|
||||
$lotw_hint = ' lotw_info_orange';
|
||||
} elseif ($diff > 7) {
|
||||
$lotw_hint = ' lotw_info_yellow';
|
||||
}
|
||||
?>
|
||||
<?php $timestamp = strtotime($row->lastupload); echo ($row->callsign == '' ? '' : ' <small id="lotw_info" class="badge badge-success'.$lotw_hint.'" data-toggle="tooltip" data-original-title="LoTW User. Last upload was '.date($custom_date_format." H:i", $timestamp).'">L</small>'); ?>
|
||||
</td>
|
||||
<?php
|
||||
|
||||
|
|
|
@ -441,3 +441,15 @@ div#station_logbooks_linked_table_paginate {
|
|||
#lotw_manual_results {
|
||||
padding-top: 10px;
|
||||
}
|
||||
|
||||
.lotw_info_yellow {
|
||||
background-image: linear-gradient(to bottom, #3fb618, yellow);
|
||||
}
|
||||
|
||||
.lotw_info_orange {
|
||||
background-image: linear-gradient(to bottom, #3fb618, orange);
|
||||
}
|
||||
|
||||
.lotw_info_red {
|
||||
background-image: linear-gradient(to bottom, #3fb618, red);
|
||||
}
|
||||
|
|
Ładowanie…
Reference in New Issue