Hide end time if only differs in seconds as we only display minutes

anyway ...
This commit is contained in:
phl0 2023-10-27 10:14:42 +02:00
parent d519d88604
commit c5f6bb0cab
No known key found for this signature in database
GPG Key ID: 48EA1E640798CA9A

View File

@ -70,8 +70,8 @@
<td><?php echo lang('general_word_datetime'); ?></td>
<?php if(($this->config->item('use_auth') && ($this->session->userdata('user_type') >= 2)) || $this->config->item('use_auth') === FALSE || ($this->config->item('show_time'))) { ?>
<td><?php $timestamp = strtotime($row->COL_TIME_ON); echo date($custom_date_format, $timestamp); $timestamp = strtotime($row->COL_TIME_ON); echo " at ".date('H:i', $timestamp); ?>
<?php if ($row->COL_TIME_ON != $row->COL_TIME_OFF) { $timestamp = strtotime($row->COL_TIME_OFF); echo " - ".date('H:i', $timestamp); } ?>
<td><?php $timestamp = strtotime($row->COL_TIME_ON); echo date($custom_date_format, $timestamp); $timestamp = strtotime($row->COL_TIME_ON); $time_on = date('H:i', $timestamp); echo " at ".$time_on; ?>
<?php $timestamp = strtotime($row->COL_TIME_OFF); $time_off = date('H:i', $timestamp); if ($time_on != $time_off) { echo " - ".$time_off; } ?>
</td>
<?php } else { ?>
<td><?php $timestamp = strtotime($row->COL_TIME_ON); echo date($custom_date_format, $timestamp); ?></td>