Merge pull request #1 from magicbug/master

update from original
这个提交包含在:
Andy 2016-02-12 22:13:15 +00:00
当前提交 8487c58e4f
共有 11 个文件被更改,包括 81 次插入176574 次删除

1
.gitignore vendored
查看文件

@ -5,3 +5,4 @@
/uploads/*.tq8
/uploads/*.TQ8
/install/*
/updates/*

查看文件

@ -22,6 +22,10 @@ More information can be found in the wiki.
Its possible to interact with your radio if you have a K3, FT-950 or a ICOM radio using a nice application that Rob (M0VFC) has put together called [CloudlogCAT](https://github.com/rmc47/CloudlogCAT). The application is still in active development and lots of new features are due.
## QSL Card Labels
I've started building out some scripts to generate labels for sticking on QSL Cards, at the moment it supports 24 label sheets, but theres no reason for it not to support more, these can be found at [Cloudlog-Labels](https://github.com/magicbug/cloudlog-labels)
## Copyright / Licence
The MIT License (MIT)
@ -57,3 +61,7 @@ SOFTWARE.
![Clublog Logo](http://www.clublog.org/images/clublog.png "Clublog Logo")
We use the [Clublog](http://www.clublog.org/) cty.xml and APIs within the DXCC elements of Cloudlog. If you're not already a member of Clublog, we recommend you go sign up!
![HamQTH Logo](https://www.hamqth.com/images/hamqth_125x125.png "HamQTH Logo")
Cloudlog supports using the callsign lookup service from [HamQTH](https://www.hamqth.com)

查看文件

@ -108,13 +108,8 @@ class adif extends CI_Controller {
break;
};
//echo date('Y-m-d', strtotime($record['qso_date']))."<br>";
//echo date('H:m', strtotime($record['time_on']))."<br>";
$this->logbook_model->import($record);
//echo $record["call"]."<br>";
//print_r($record);
};
unlink('./uploads/'.$data['upload_data']['file_name']);
@ -126,39 +121,6 @@ class adif extends CI_Controller {
}
}
function test() {
// Set memory limit to unlimited to allow heavy usage
ini_set('memory_limit', '-1');
set_time_limit(0);
$this->load->model('logbook_model');
$this->load->library('adif_parser');
$this->adif_parser->load_from_file('./uploads/2e0sql.ADI');
$this->adif_parser->initialize();
while($record = $this->adif_parser->get_record())
{
if(count($record) == 0)
{
break;
};
//echo date('Y-m-d', strtotime($record['qso_date']))."<br>";
//echo date('H:m', strtotime($record['time_on']))."<br>";
$this->logbook_model->import($record);
//echo $record["call"]."<br>";
//print_r($record);
};
}
}
/* End of file adif.php */

查看文件

@ -1,14 +0,0 @@
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');
class Welcome extends CI_Controller {
public function index()
{
test
}
}
/* End of file welcome.php */
/* Location: ./application/controllers/welcome.php */

查看文件

@ -1,65 +0,0 @@
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');
class Hamli {
/*
Communicates with the ham.li API functions
*/
public function callsign($callsign)
{
ini_set ('display_errors', 1);
$jsonurl = "http://search.ham.li/api/call/".$callsign;
$json = @file_get_contents($jsonurl,0,null,null);
$json_output = json_decode($json);
if(isset($json_output)) {
foreach ($json_output as $name => $callsign) {
if(isset($name)) {
$data['callsign'] = strtoupper($name);
} else {
$data['callsign'] = $callsign;
}
if (isset($callsign->first_name)) {
$data['name'] = $callsign->first_name;
} else {
$data['name'] = "";
}
if(isset($callsign->gridsquare)) {
$data['gridsquare'] = $callsign->gridsquare;
} else {
$data['gridsquare'] = "";
}
if(isset($callsign->city)) {
$data['city'] = ucfirst(strtolower(($callsign->city)));
} else {
$data['city'] = "";
}
if (isset($callsign->latitude)) {
$data['lat'] = ucfirst($callsign->latitude);
} else {
$data['lat'] = "";
}
if (isset($callsign->longitude)) {
$data['long'] = ucfirst($callsign->longitude);
} else {
$data['long'] = "";
}
return $data;
}
}
}
}
/* End of file hamli.php */

查看文件

@ -276,7 +276,7 @@ class Logbook_model extends CI_Model {
function get_qsos($num, $offset) {
$this->db->select('COL_CALL, COL_BAND, COL_TIME_ON, COL_RST_RCVD, COL_RST_SENT, COL_MODE, COL_NAME, COL_COUNTRY, COL_PRIMARY_KEY, COL_SAT_NAME, COL_GRIDSQUARE, COL_QSL_RCVD, COL_EQSL_QSL_RCVD, COL_EQSL_QSL_SENT, COL_QSL_SENT, COL_STX_STRING, COL_SRX_STRING, COL_OPERATOR, COL_STATION_CALLSIGN');
$this->db->select('COL_CALL, COL_BAND, COL_TIME_ON, COL_RST_RCVD, COL_RST_SENT, COL_MODE, COL_NAME, COL_COUNTRY, COL_PRIMARY_KEY, COL_SAT_NAME, COL_GRIDSQUARE, COL_QSL_RCVD, COL_EQSL_QSL_RCVD, COL_EQSL_QSL_SENT, COL_QSL_SENT, COL_STX_STRING, COL_SRX_STRING, COL_OPERATOR, COL_STATION_CALLSIGN, COL_LOTW_QSL_SENT, COL_LOTW_QSL_RCVD');
$this->db->order_by("COL_TIME_ON", "desc");
$query = $this->db->get($this->config->item('table_name'), $num, $offset);

查看文件

@ -217,6 +217,8 @@ class User_Model extends CI_Model {
'user_type' => $u->row()->user_type,
'user_callsign' => $u->row()->user_callsign,
'user_locator' => $u->row()->user_locator,
'user_lotw_name' => $u->row()->user_lotw_name,
'user_eqsl_name' => $u->row()->user_eqsl_name,
'user_hash' => $this->_hash($u->row()->user_id."-".$u->row()->user_type)
);

查看文件

@ -10,7 +10,19 @@
<td>Country</td>
<?php if(($this->config->item('use_auth')) && ($this->session->userdata('user_type') >= 2)) { ?>
<td>QSL</td>
<?php if($this->session->userdata('user_eqsl_name') != "") { ?>
<td>eQSL</td>
<?php } else { ?>
<td></td>
<?php } ?>
<?php if($this->session->userdata('user_lotw_name') != "") { ?>
<td>LoTW</td>
<?php } else { ?>
<td></td>
<?php } ?>
<td></td>
<?php } ?>
</tr>
@ -46,12 +58,23 @@
<img src="<?php echo base_url();?>images/icons/qslcard_sent.png" alt="QSL Cards sent" title="QSL Cards sent" />
<?php } ?>
</td>
<?php if ($this->session->userdata('user_eqsl_name') != "" && $row->COL_EQSL_QSL_SENT != ''){ ?>
<td class="eqsl">
<?php if ($row->COL_EQSL_QSL_SENT != ''){ ?>
<span class="eqsl-<?php echo ($row->COL_EQSL_QSL_SENT=='Y')?'green':'red'?>">&#9650;</span>
<span class="eqsl-<?php echo ($row->COL_EQSL_QSL_RCVD=='Y')?'green':'red'?>">&#9660;</span>
</td>
<?php } ?>
<?php if($this->session->userdata('user_lotw_name') != "") { ?>
<td class="lotw">
<?php if ($row->COL_LOTW_QSL_SENT != ''){ ?>
<span class="lotw-<?php echo ($row->COL_LOTW_QSL_SENT=='Y')?'green':'red'?>">&#9650;</span>
<span class="lotw-<?php echo ($row->COL_LOTW_QSL_RCVD=='Y')?'green':'red'?>">&#9660;</span>
<?php } ?>
</td>
<?php } ?>
<td><a class="editbox" href="<?php echo site_url('qso/edit'); ?>/<?php echo $row->COL_PRIMARY_KEY; ?>" ><img src="<?php echo base_url(); ?>/images/application_edit.png" width="16" height="16" alt="Edit" />
</a></td>
<?php } ?>
@ -74,3 +97,16 @@ TD.eqsl{
color: #F00;
font-size: 1.1em;
}
TD.lotw{
width: 33px;
}
.lotw-green{
color: #00A000;
font-size: 1.1em;
}
.lotw-red{
color: #F00;
font-size: 1.1em;
}
</style>

查看文件

@ -10,7 +10,12 @@
<td>Country</td>
<?php if(($this->config->item('use_auth')) && ($this->session->userdata('user_type') >= 2)) { ?>
<td>QSL</td>
<?php if($this->session->userdata('user_eqsl_name') != "") { ?>
<td>eQSL</td>
<?php } ?>
<?php if($this->session->userdata('user_lotw_name') != "") { ?>
<td>LoTW</td>
<?php } ?>
<td></td>
<?php } ?>
</tr>
@ -46,12 +51,23 @@
<img src="<?php echo base_url();?>images/icons/qslcard_sent.png" alt="QSL Cards sent" title="QSL Cards sent" />
<?php } ?>
</td>
<?php if ($this->session->userdata('user_eqsl_name') != "" && $row->COL_EQSL_QSL_SENT != ''){ ?>
<td class="eqsl">
<?php if ($row->COL_EQSL_QSL_SENT != ''){ ?>
<span class="eqsl-<?php echo ($row->COL_EQSL_QSL_SENT=='Y')?'green':'red'?>">&#9650;</span>
<span class="eqsl-<?php echo ($row->COL_EQSL_QSL_RCVD=='Y')?'green':'red'?>">&#9660;</span>
</td>
<?php } ?>
<?php if($this->session->userdata('user_lotw_name') != "") { ?>
<td class="lotw">
<?php if ($row->COL_LOTW_QSL_SENT != ''){ ?>
<span class="lotw-<?php echo ($row->COL_LOTW_QSL_SENT=='Y')?'green':'red'?>">&#9650;</span>
<span class="lotw-<?php echo ($row->COL_LOTW_QSL_RCVD=='Y')?'green':'red'?>">&#9660;</span>
<?php } ?>
</td>
<?php } ?>
<td><a class="editbox" href="<?php echo site_url('qso/edit'); ?>/<?php echo $row->COL_PRIMARY_KEY; ?>" ><img src="<?php echo base_url(); ?>/images/application_edit.png" width="16" height="16" alt="Edit" />
</a></td>
<?php if($this->config->item('callsign_tags') == true) { ?>
@ -88,4 +104,16 @@ TD.eqsl{
color: #F00;
font-size: 1.1em;
}
TD.lotw{
width: 33px;
}
.lotw-green{
color: #00A000;
font-size: 1.1em;
}
.lotw-red{
color: #F00;
font-size: 1.1em;
}
</style>

查看文件

@ -126,8 +126,8 @@ margin: 10px 0;
<?php } ?>
<?php } ?>
<h3>LoTW</h3>
<?php if($row->COL_LOTW_QSL_RCVD == "Y") { ?>
<h3>LoTW</h3>
<p>This QSO is confirmed on Lotw</p>
<?php } ?>
</div>

文件差异内容过多而无法显示 加载差异