Removed unused functions at Dashboard / Secured webadif
这个提交包含在:
		
							父节点
							
								
									ef65d6a7c4
								
							
						
					
					
						当前提交
						8e5dacea01
					
				
					共有  2 个文件被更改,包括 34 次插入 和 86 次删除
				
			
		|  | @ -212,42 +212,4 @@ class Dashboard extends CI_Controller { | ||||||
| 	} | 	} | ||||||
| 	 | 	 | ||||||
| 	 | 	 | ||||||
| 	function todays_map() { |  | ||||||
| 		$this->load->library('qra'); |  | ||||||
| 		$this->load->model('logbook_model'); |  | ||||||
| 		// TODO: Auth
 |  | ||||||
| 		$qsos = $this->logbook_model->get_todays_qsos(''); |  | ||||||
| 
 |  | ||||||
| 	 |  | ||||||
| 		echo "{\"markers\": ["; |  | ||||||
| 
 |  | ||||||
| 		foreach ($qsos->result() as $row) { |  | ||||||
| 			//print_r($row);
 |  | ||||||
| 			if($row->COL_GRIDSQUARE != null) { |  | ||||||
| 				$stn_loc = $this->qra->qra2latlong($row->COL_GRIDSQUARE); |  | ||||||
| 				echo "{\"point\":new GLatLng(".$stn_loc[0].",".$stn_loc[1]."), \"html\":\"Callsign: ".$row->COL_CALL."<br />Date/Time: ".$row->COL_TIME_ON."<br />Band: ".$row->COL_BAND."<br />Mode: "; |  | ||||||
| 				echo $row->COL_SUBMODE==null?$row->COL_MODE:$row->COL_SUBMODE; |  | ||||||
| 				echo "\",\"label\":\"".$row->COL_CALL."\"},"; |  | ||||||
| 			} else { |  | ||||||
| 				$query = $this->db->query(' |  | ||||||
| 					SELECT * |  | ||||||
| 					FROM dxcc_entities |  | ||||||
| 					WHERE prefix = SUBSTRING( \''.$row->COL_CALL.'\', 1, LENGTH( prefix ) ) |  | ||||||
| 					ORDER BY LENGTH( prefix ) DESC |  | ||||||
| 					LIMIT 1  |  | ||||||
| 				'); |  | ||||||
| 				 |  | ||||||
| 				foreach ($query->result() as $dxcc) { |  | ||||||
| 					echo "{\"point\":new GLatLng(".$dxcc->lat.",".$dxcc->long."), \"html\":\"Callsign: ".$row->COL_CALL."<br />Date/Time: ".$row->COL_TIME_ON."<br />Band: ".$row->COL_BAND."<br />Mode: "; |  | ||||||
| 					echo $row->COL_SUBMODE==null?$row->COL_MODE:$row->COL_SUBMODE; |  | ||||||
| 					echo "\",\"label\":\"".$row->COL_CALL."\"},"; |  | ||||||
| 	} | 	} | ||||||
| 			} |  | ||||||
| 			 |  | ||||||
| 		} |  | ||||||
| 		echo "]"; |  | ||||||
| 		echo "}"; |  | ||||||
| 
 |  | ||||||
| 	} |  | ||||||
| 	 |  | ||||||
| } |  | ||||||
|  |  | ||||||
|  | @ -1501,6 +1501,11 @@ class Logbook_model extends CI_Model { | ||||||
|      * Function returns the QSOs from the logbook, which have not been either marked as uploaded to webADIF |      * Function returns the QSOs from the logbook, which have not been either marked as uploaded to webADIF | ||||||
|      */ |      */ | ||||||
|     function get_webadif_qsos($station_id,$from = null, $to = null){ |     function get_webadif_qsos($station_id,$from = null, $to = null){ | ||||||
|  | 	    $CI =& get_instance(); | ||||||
|  | 	    $CI->load->model('Stations'); | ||||||
|  | 	    if (!$CI->Stations->check_station_is_accessible($station_id)) { | ||||||
|  | 		    return; | ||||||
|  | 	    } | ||||||
| 	    $sql = " | 	    $sql = " | ||||||
| 			SELECT qsos.*, station_profile.*, dxcc_entities.name as station_country | 			SELECT qsos.*, station_profile.*, dxcc_entities.name as station_country | ||||||
| 			FROM %s qsos | 			FROM %s qsos | ||||||
|  | @ -1737,25 +1742,6 @@ class Logbook_model extends CI_Model { | ||||||
|         return $query; |         return $query; | ||||||
|     } |     } | ||||||
| 
 | 
 | ||||||
|     function get_date_qsos($date) { |  | ||||||
|         $this->db->select('COL_CALL, COL_BAND, COL_TIME_ON, COL_RST_RCVD, COL_RST_SENT, COL_MODE, COL_SUBMODE, COL_NAME, COL_COUNTRY, COL_PRIMARY_KEY, COL_SAT_NAME'); |  | ||||||
|         $this->db->order_by("COL_TIME_ON", "desc"); |  | ||||||
|         $start = $date." 00:00:00"; |  | ||||||
|         $end = $date." 23:59:59"; |  | ||||||
| 
 |  | ||||||
|         $this->db->where("COL_TIME_ON BETWEEN '".$start."' AND '".$end."'"); |  | ||||||
|         $query = $this->db->get($this->config->item('table_name')); |  | ||||||
| 
 |  | ||||||
|         return $query; |  | ||||||
|     } |  | ||||||
| 
 |  | ||||||
|   function get_todays_qsos() { |  | ||||||
|     $morning = date('Y-m-d 00:00:00'); |  | ||||||
|     $night = date('Y-m-d 23:59:59'); |  | ||||||
|     $query = $this->db->query('SELECT * FROM '.$this->config->item('table_name').' WHERE COL_TIME_ON between \''.$morning.'\' AND \''.$night.'\''); |  | ||||||
|     return $query; |  | ||||||
|   } |  | ||||||
| 
 |  | ||||||
|     function totals_year() { |     function totals_year() { | ||||||
| 
 | 
 | ||||||
|     $CI =& get_instance(); |     $CI =& get_instance(); | ||||||
|  |  | ||||||
		正在加载…
	
		在新工单中引用