Fixed a range of errors
这个提交包含在:
		
							父节点
							
								
									4f2fc64c01
								
							
						
					
					
						当前提交
						e7902db33a
					
				
					共有  4 个文件被更改,包括 87 次插入 和 63 次删除
				
			
		|  | @ -198,6 +198,7 @@ class Logbook extends CI_Controller { | |||
|         $CI->load->model('logbooks_model'); | ||||
|         $logbooks_locations_array = $CI->logbooks_model->list_logbook_relationships($this->session->userdata('active_station_logbook')); | ||||
| 
 | ||||
| 		if(!empty($logbooks_locations_array)) {  | ||||
| 			if($type == "SAT") { | ||||
| 				$this->db->where('COL_PROP_MODE', 'SAT'); | ||||
| 			} else { | ||||
|  | @ -219,6 +220,7 @@ class Logbook extends CI_Controller { | |||
| 			{ | ||||
| 				return true; | ||||
| 			} | ||||
| 		} | ||||
| 		return false; | ||||
| 	} | ||||
| 
 | ||||
|  | @ -272,6 +274,7 @@ class Logbook extends CI_Controller { | |||
|         $CI->load->model('logbooks_model'); | ||||
|         $logbooks_locations_array = $CI->logbooks_model->list_logbook_relationships($this->session->userdata('active_station_logbook')); | ||||
| 
 | ||||
| 		if(!empty($logbooks_locations_array)) {  | ||||
| 			if($type == "SAT") { | ||||
| 				$this->db->where('COL_PROP_MODE', 'SAT'); | ||||
| 			} else { | ||||
|  | @ -294,6 +297,13 @@ class Logbook extends CI_Controller { | |||
| 			echo json_encode($return, JSON_PRETTY_PRINT); | ||||
| 
 | ||||
| 			return; | ||||
| 		} else { | ||||
| 			$return['workedBefore'] = false; | ||||
| 
 | ||||
| 			header('Content-Type: application/json'); | ||||
| 			echo json_encode($return, JSON_PRETTY_PRINT); | ||||
| 			return; | ||||
| 		} | ||||
| 	} | ||||
| 
 | ||||
| 	function jsonlookupcallsign($callsign, $type, $band, $mode) { | ||||
|  | @ -309,6 +319,7 @@ class Logbook extends CI_Controller { | |||
|         $CI->load->model('logbooks_model'); | ||||
|         $logbooks_locations_array = $CI->logbooks_model->list_logbook_relationships($this->session->userdata('active_station_logbook')); | ||||
| 
 | ||||
| 		if(!empty($logbooks_locations_array)) {  | ||||
| 			if($type == "SAT") { | ||||
| 				$this->db->where('COL_PROP_MODE', 'SAT'); | ||||
| 			} else { | ||||
|  | @ -329,8 +340,13 @@ class Logbook extends CI_Controller { | |||
| 
 | ||||
| 			header('Content-Type: application/json'); | ||||
| 			echo json_encode($return, JSON_PRETTY_PRINT); | ||||
| 
 | ||||
| 			return; | ||||
| 		} else { | ||||
| 			$return['workedBefore'] = false; | ||||
| 			header('Content-Type: application/json'); | ||||
| 			echo json_encode($return, JSON_PRETTY_PRINT); | ||||
| 			return; | ||||
| 		} | ||||
| 	} | ||||
| 
 | ||||
| 
 | ||||
|  | @ -416,6 +432,7 @@ class Logbook extends CI_Controller { | |||
| 
 | ||||
| 		$html = ""; | ||||
| 
 | ||||
| 		if(!empty($logbooks_locations_array)) {  | ||||
| 	    $this->db->select(''.$this->config->item('table_name').'.COL_CALL, '.$this->config->item('table_name').'.COL_BAND, '.$this->config->item('table_name').'.COL_TIME_ON, '.$this->config->item('table_name').'.COL_RST_RCVD, '.$this->config->item('table_name').'.COL_RST_SENT, '.$this->config->item('table_name').'.COL_MODE, '.$this->config->item('table_name').'.COL_SUBMODE, '.$this->config->item('table_name').'.COL_PRIMARY_KEY, '.$this->config->item('table_name').'.COL_SAT_NAME, '.$this->config->item('table_name').'.COL_GRIDSQUARE, '.$this->config->item('table_name').'.COL_QSL_RCVD, '.$this->config->item('table_name').'.COL_EQSL_QSL_RCVD, '.$this->config->item('table_name').'.COL_EQSL_QSL_SENT, '.$this->config->item('table_name').'.COL_QSL_SENT, '.$this->config->item('table_name').'.COL_STX, '.$this->config->item('table_name').'.COL_STX_STRING, '.$this->config->item('table_name').'.COL_SRX, '.$this->config->item('table_name').'.COL_SRX_STRING, '.$this->config->item('table_name').'.COL_LOTW_QSL_SENT, '.$this->config->item('table_name').'.COL_LOTW_QSL_RCVD, '.$this->config->item('table_name').'.COL_VUCC_GRIDS, station_profile.*'); | ||||
| 	    $this->db->from($this->config->item('table_name')); | ||||
| 
 | ||||
|  | @ -428,8 +445,9 @@ class Logbook extends CI_Controller { | |||
| 		$this->db->limit(5); | ||||
| 
 | ||||
| 		$query = $this->db->get(); | ||||
| 		} | ||||
| 
 | ||||
| 		if ($query->num_rows() > 0) | ||||
| 		if (!empty($logbooks_locations_array) && $query->num_rows() > 0) | ||||
| 		{ | ||||
| 			$html .= "<div class=\"table-responsive\">"; | ||||
| 			$html .= "<table class=\"table\">"; | ||||
|  |  | |||
|  | @ -595,12 +595,16 @@ class Logbook_model extends CI_Model { | |||
|     $CI->load->model('logbooks_model'); | ||||
|     $logbooks_locations_array = $CI->logbooks_model->list_logbook_relationships($this->session->userdata('active_station_logbook')); | ||||
| 
 | ||||
|     if(!empty($logbooks_locations_array)) { | ||||
|       $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->where_in('station_id', $logbooks_locations_array); | ||||
|       $this->db->order_by("COL_TIME_ON", "desc"); | ||||
|       $this->db->limit($num); | ||||
| 
 | ||||
|       return $this->db->get($this->config->item('table_name')); | ||||
|     } else { | ||||
|       return false; | ||||
|     } | ||||
|   } | ||||
| 
 | ||||
|   /* | ||||
|  |  | |||
|  | @ -82,6 +82,7 @@ function echo_table_col($row, $name) { | |||
| 
 | ||||
| 			<?php | ||||
| 			$i = 0; | ||||
| 			if(!empty($last_five_qsos) > 0) { | ||||
| 			foreach ($last_five_qsos->result() as $row) { ?>
 | ||||
| 				<?php  echo '<tr class="tr'.($i & 1).'">'; ?>
 | ||||
| 
 | ||||
|  | @ -113,7 +114,7 @@ function echo_table_col($row, $name) { | |||
| 						echo_table_col($row, $this->session->userdata('user_column4')==""?'Band':$this->session->userdata('user_column4')); | ||||
| 					?>
 | ||||
| 				</tr> | ||||
| 			<?php $i++; } ?>
 | ||||
| 			<?php $i++; } } ?>
 | ||||
| 		</table> | ||||
| 	</div> | ||||
|   </div> | ||||
|  |  | |||
|  | @ -525,6 +525,7 @@ | |||
| 			  } | ||||
| 
 | ||||
| 			  $i = 0; | ||||
|             if($query != false) {   | ||||
|             foreach ($query->result() as $row) { | ||||
|               	echo '<tr class="tr'.($i & 1).'">'; | ||||
|                     echo '<td>'; | ||||
|  | @ -545,7 +546,7 @@ | |||
|                     <td><?php echo $row->COL_BAND; ?></td>
 | ||||
|                     <?php } ?>
 | ||||
|                   </tr> | ||||
|               <?php $i++; } ?>
 | ||||
|               <?php $i++; } } ?>
 | ||||
|             </table> | ||||
|           </div> | ||||
|         </div> | ||||
|  |  | |||
		正在加载…
	
		在新工单中引用