Merge pull request #2670 from phl0/emptyContestResults
Fix lookups for empty contest sessions
这个提交包含在:
		
						当前提交
						0372af2766
					
				
					共有  2 个文件被更改,包括 2 次插入 和 2 次删除
				
			
		| 
						 | 
					@ -188,7 +188,7 @@ class Contesting extends CI_Controller {
 | 
				
			||||||
		$result = $this->Contesting_model->checkIfWorkedBefore($call, $band, $mode, $contest);
 | 
							$result = $this->Contesting_model->checkIfWorkedBefore($call, $band, $mode, $contest);
 | 
				
			||||||
		
 | 
							
 | 
				
			||||||
		header('Content-Type: application/json');
 | 
							header('Content-Type: application/json');
 | 
				
			||||||
		if ($result->num_rows()) {
 | 
							if ($result && $result->num_rows()) {
 | 
				
			||||||
			echo json_encode(array('message' => 'Worked before'));
 | 
								echo json_encode(array('message' => 'Worked before'));
 | 
				
			||||||
		}
 | 
							}
 | 
				
			||||||
		return;
 | 
							return;
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -214,7 +214,7 @@ class Contesting_model extends CI_Model {
 | 
				
			||||||
 | 
					
 | 
				
			||||||
		$contest_session = $this->getSession();
 | 
							$contest_session = $this->getSession();
 | 
				
			||||||
		
 | 
							
 | 
				
			||||||
		if ($contest_session) {
 | 
							if ($contest_session && $contest_session->qso != "") {
 | 
				
			||||||
			$qsoarray = explode(',', $contest_session->qso);
 | 
								$qsoarray = explode(',', $contest_session->qso);
 | 
				
			||||||
	
 | 
						
 | 
				
			||||||
			$date = DateTime::createFromFormat('d-m-Y H:i:s', $qsoarray[0]);
 | 
								$date = DateTime::createFromFormat('d-m-Y H:i:s', $qsoarray[0]);
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		正在加载…
	
		在新工单中引用