[logbook] fix table header html markup & contest serial info

pull/1231/head
ShadowMov 2021-10-16 00:03:05 +08:00
rodzic 92e006bc19
commit 5052f5505c
1 zmienionych plików z 11 dodań i 11 usunięć

Wyświetl plik

@ -1,23 +1,23 @@
<?php
function echo_table_header_col($ctx, $name) {
switch($name) {
case 'Mode': echo '<th>'.$ctx->lang->line('gen_hamradio_mode').'</th>'; break;
case 'RSTS': echo '<th class="d-none d-sm-table-cell">'.$ctx->lang->line('gen_hamradio_rsts').'</th>'; break;
case 'RSTR': echo '<th class="d-none d-sm-table-cell">'.$ctx->lang->line('gen_hamradio_rstr').'</th>'; break;
case 'Country': echo '<th>'.$ctx->lang->line('general_word_country').'</th>'; break;
case 'IOTA': echo '<th>'.$ctx->lang->line('gen_hamradio_iota').'</th>'; break;
case 'SOTA': echo '<th>'.$ctx->lang->line('gen_hamradio_sota').'</th>'; break;
case 'State': echo '<th>'.$ctx->lang->line('gen_hamradio_state').'</th>'; break;
case 'Grid': echo '<th>'.$ctx->lang->line('gen_hamradio_gridsquare').'</th>'; break;
case 'Band': echo '<th>'.$ctx->lang->line('gen_hamradio_band').'</th>'; break;
case 'Mode': echo '<td>'.$ctx->lang->line('gen_hamradio_mode').'</td>'; break;
case 'RSTS': echo '<td>'.$ctx->lang->line('gen_hamradio_rsts').'</td>'; break;
case 'RSTR': echo '<td>'.$ctx->lang->line('gen_hamradio_rstr').'</td>'; break;
case 'Country': echo '<td>'.$ctx->lang->line('general_word_country').'</td>'; break;
case 'IOTA': echo '<td>'.$ctx->lang->line('gen_hamradio_iota').'</td>'; break;
case 'SOTA': echo '<td>'.$ctx->lang->line('gen_hamradio_sota').'</td>'; break;
case 'State': echo '<td>'.$ctx->lang->line('gen_hamradio_state').'</td>'; break;
case 'Grid': echo '<td>'.$ctx->lang->line('gen_hamradio_gridsquare').'</td>'; break;
case 'Band': echo '<td>'.$ctx->lang->line('gen_hamradio_band').'</td>'; break;
}
}
function echo_table_col($row, $name) {
switch($name) {
case 'Mode': echo '<td>'; echo $row->COL_SUBMODE==null?$row->COL_MODE:$row->COL_SUBMODE . '</td>'; break;
case 'RSTS': echo '<td class="d-none d-sm-table-cell">' . $row->COL_RST_SENT; if ($row->COL_STX_STRING) { echo '<span class="label">' . $row->COL_STX_STRING . '</span>';} echo '</td>'; break;
case 'RSTR': echo '<td class="d-none d-sm-table-cell">' . $row->COL_RST_RCVD; if ($row->COL_SRX_STRING) { echo '<span class="label">' . $row->COL_SRX_STRING . '</span>';} echo '</td>'; break;
case 'RSTS': echo '<td>' . $row->COL_RST_SENT; if ($row->COL_STX) { echo '<span class="badge badge-light">' . $row->COL_STX . '</span>';} if ($row->COL_STX_STRING) { echo '<span class="badge badge-light">' . $row->COL_STX_STRING . '</span>';} echo '</td>'; break;
case 'RSTR': echo '<td>' . $row->COL_RST_RCVD; if ($row->COL_SRX) { echo '<span class="badge badge-light">' . $row->COL_SRX . '</span>';} if ($row->COL_SRX_STRING) { echo '<span class="badge badge-light">' . $row->COL_SRX_STRING . '</span>';} echo '</td>'; break;
case 'Country': echo '<td>' . ucwords(strtolower(($row->COL_COUNTRY))) . '</td>'; break;
case 'IOTA': echo '<td>' . ($row->COL_IOTA) . '</td>'; break;
case 'SOTA': echo '<td>' . ($row->COL_SOTA_REF) . '</td>'; break;