html5 datepicker
这个提交包含在:
父节点
17f39639be
当前提交
034c1115e2
共有 2 个文件被更改,包括 274 次插入 和 267 次删除
|
|
@ -117,13 +117,9 @@ class adif_data extends CI_Model {
|
|||
|
||||
// If date is set, we format the date and add it to the where-statement
|
||||
if ($from) {
|
||||
$from = DateTime::createFromFormat('d/m/Y', $from);
|
||||
$from = $from->format('Y-m-d');
|
||||
$this->db->where("date(".$this->config->item('table_name').".COL_TIME_ON) >= '".$from."'");
|
||||
}
|
||||
if ($to) {
|
||||
$to = DateTime::createFromFormat('d/m/Y', $to);
|
||||
$to = $to->format('Y-m-d');
|
||||
$this->db->where("date(".$this->config->item('table_name').".COL_TIME_ON) <= '".$to."'");
|
||||
}
|
||||
if ($exportLotw) {
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
<div class="container adif">
|
||||
|
||||
<h2><?php echo $page_title; ?></h2>
|
||||
|
|
@ -13,7 +12,13 @@
|
|||
<div class="card-header">
|
||||
<ul class="nav nav-tabs card-header-tabs pull-right" role="tablist">
|
||||
<li class="nav-item">
|
||||
<a class="nav-link <?php if($showtab == '' || $showtab == 'adif') { echo 'active'; } ?>" id="import-tab" data-bs-toggle="tab" href="#import" role="tab" aria-controls="import" aria-selected="<?php if ($showtab == '' || $showtab == 'adif') { echo 'true'; } else { echo 'false'; } ?>"><?php echo lang('adif_import')?></a>
|
||||
<a class="nav-link <?php if ($showtab == '' || $showtab == 'adif') {
|
||||
echo 'active';
|
||||
} ?>" id="import-tab" data-bs-toggle="tab" href="#import" role="tab" aria-controls="import" aria-selected="<?php if ($showtab == '' || $showtab == 'adif') {
|
||||
echo 'true';
|
||||
} else {
|
||||
echo 'false';
|
||||
} ?>"><?php echo lang('adif_import') ?></a>
|
||||
</li>
|
||||
<li class="nav-item">
|
||||
<a class="nav-link" id="export-tab" data-bs-toggle="tab" href="#export" role="tab" aria-controls="export" aria-selected="false"><?php echo lang('adif_export') ?></a>
|
||||
|
|
@ -22,14 +27,24 @@
|
|||
<a class="nav-link" id="lotw-tab" data-bs-toggle="tab" href="#lotw" role="tab" aria-controls="lotw" aria-selected="false"><?php echo lang('lotw_title') ?></a>
|
||||
</li>
|
||||
<li class="nav-item">
|
||||
<a class="nav-link <?php if ($showtab == 'dcl') { echo 'active'; } ?>" id="dcl-tab" data-bs-toggle="tab" href="#dcl" role="tab" aria-controls="dcl" aria-selected="<?php if ($showtab == 'dcl') { echo 'true'; } else { echo 'false'; } ?>"><?php echo lang('darc_dcl')?></a>
|
||||
<a class="nav-link <?php if ($showtab == 'dcl') {
|
||||
echo 'active';
|
||||
} ?>" id="dcl-tab" data-bs-toggle="tab" href="#dcl" role="tab" aria-controls="dcl" aria-selected="<?php if ($showtab == 'dcl') {
|
||||
echo 'true';
|
||||
} else {
|
||||
echo 'false';
|
||||
} ?>"><?php echo lang('darc_dcl') ?></a>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<div class="card-body">
|
||||
<div class="tab-content">
|
||||
<div class="tab-pane <?php if($showtab == '' || $showtab == 'adif') { echo 'active'; } else { echo 'fade'; } ?>" id="import" role="tabpanel" aria-labelledby="home-tab">
|
||||
<div class="tab-pane <?php if ($showtab == '' || $showtab == 'adif') {
|
||||
echo 'active';
|
||||
} else {
|
||||
echo 'fade';
|
||||
} ?>" id="import" role="tabpanel" aria-labelledby="home-tab">
|
||||
|
||||
<?php if (isset($error) && ($showtab == '' || $showtab == 'adif')) { ?>
|
||||
<div class="alert alert-danger" role="alert">
|
||||
|
|
@ -44,7 +59,9 @@
|
|||
<select name="station_profile" class="form-select mb-2 me-sm-2" style="width: 20%;">
|
||||
<option value="0"><?php echo lang('adif_select_stationlocation') ?></option>
|
||||
<?php foreach ($station_profile->result() as $station) { ?>
|
||||
<option value="<?php echo $station->station_id; ?>" <?php if ($station->station_id == $this->stations->find_active()) { echo " selected =\"selected\""; } ?>><?php echo lang('gen_hamradio_callsign') . ": "?><?php echo $station->station_callsign; ?> (<?php echo $station->station_profile_name; ?>)</option>
|
||||
<option value="<?php echo $station->station_id; ?>" <?php if ($station->station_id == $this->stations->find_active()) {
|
||||
echo " selected =\"selected\"";
|
||||
} ?>><?php echo lang('gen_hamradio_callsign') . ": " ?><?php echo $station->station_callsign; ?> (<?php echo $station->station_profile_name; ?>)</option>
|
||||
<?php } ?>
|
||||
</select>
|
||||
<label class="visually-hidden" for="inlineFormInputName2"><?php echo lang('adif_file_label') ?></label>
|
||||
|
|
@ -140,28 +157,18 @@
|
|||
<select name="station_profile" class="form-select mb-2 me-sm-2" style="width: 20%;">
|
||||
<option value="0"><?php echo lang('adif_select_stationlocation') ?></option>
|
||||
<?php foreach ($station_profile->result() as $station) { ?>
|
||||
<option value="<?php echo $station->station_id; ?>" <?php if ($station->station_id == $this->stations->find_active()) { echo " selected =\"selected\""; } ?>><?php echo lang('gen_hamradio_callsign') . ": "?><?php echo $station->station_callsign; ?> (<?php echo $station->station_profile_name; ?>)</option>
|
||||
<option value="<?php echo $station->station_id; ?>" <?php if ($station->station_id == $this->stations->find_active()) {
|
||||
echo " selected =\"selected\"";
|
||||
} ?>><?php echo lang('gen_hamradio_callsign') . ": " ?><?php echo $station->station_callsign; ?> (<?php echo $station->station_profile_name; ?>)</option>
|
||||
<?php } ?>
|
||||
</select>
|
||||
<p class="card-text"><?php echo lang('gen_from_date') . ": "?></p>
|
||||
<div class="row">
|
||||
<div class="input-group date col-md-3" id="datetimepicker1" data-target-input="nearest">
|
||||
<input name="from" type="text" placeholder="DD/MM/YYYY" class="form-control datetimepicker-input" data-bs-target="#datetimepicker1"/>
|
||||
<div class="input-group-append" data-bs-target="#datetimepicker1" data-bs-toggle="datetimepicker">
|
||||
<div class="input-group-text"><i class="fa fa-calendar"></i></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<br>
|
||||
<label for="from"><?php echo lang('gen_from_date') . ": " ?></label>
|
||||
<input name="from" id="from" type="date" class="form-control w-auto">
|
||||
<br>
|
||||
<label for="to"><?php echo lang('gen_to_date') . ": " ?></label>
|
||||
<input name="to" id="to" type="date" class="form-control w-auto">
|
||||
|
||||
<p class="card-text"><?php echo lang('gen_to_date') . ": "?></p>
|
||||
<div class="row">
|
||||
<div class="input-group date col-md-3" id="datetimepicker2" data-target-input="nearest">
|
||||
<input name="to" type="text" placeholder="DD/MM/YYYY" class="form-control datetimepicker-input" data-bs-target="#datetimepicker2"/>
|
||||
<div class="input-group-append" data-bs-target="#datetimepicker2" data-bs-toggle="datetimepicker">
|
||||
<div class="input-group-text"><i class="fa fa-calendar"></i></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<br>
|
||||
<div class="mb-3 row">
|
||||
<div class="col-md-10">
|
||||
|
|
@ -223,7 +230,11 @@
|
|||
<button type="submit" class="btn-sm btn-primary" value="Export"><?php echo lang('adif_mark_qso_as_exported_to_lotw') ?></button>
|
||||
</form>
|
||||
</div>
|
||||
<div class="tab-pane <?php if ($showtab == 'dcl') { echo 'active'; } else { echo 'fade'; } ?>" id="dcl" role="tabpanel" aria-labelledby="home-tab">
|
||||
<div class="tab-pane <?php if ($showtab == 'dcl') {
|
||||
echo 'active';
|
||||
} else {
|
||||
echo 'fade';
|
||||
} ?>" id="dcl" role="tabpanel" aria-labelledby="home-tab">
|
||||
<?php if (isset($error) && $showtab == 'dcl') { ?>
|
||||
<div class="alert alert-danger" role="alert">
|
||||
<?php echo $error; ?>
|
||||
|
|
|
|||
正在加载…
在新工单中引用