Added a view for uploading TQ8 (LoTW signed files). Working on the controller for functionality yet.
这个提交包含在:
		
							父节点
							
								
									cbe6635271
								
							
						
					
					
						当前提交
						bc17566e49
					
				
					共有  3 个文件被更改,包括 64 次插入 和 0 次删除
				
			
		|  | @ -167,4 +167,43 @@ class Lotw extends CI_Controller { | ||||||
| 			} | 			} | ||||||
| 		} | 		} | ||||||
| 	} // end function
 | 	} // end function
 | ||||||
|  | 	 | ||||||
|  | 	public function export() {	 | ||||||
|  | 	$data['page_title'] = "LoTW .TQ8 Upload"; | ||||||
|  | 
 | ||||||
|  | 		$config['upload_path'] = './uploads/'; | ||||||
|  | 		$config['allowed_types'] = 'tq8|TQ8'; | ||||||
|  | 
 | ||||||
|  | 		$this->load->library('upload', $config); | ||||||
|  | 
 | ||||||
|  | 		if ( ! $this->upload->do_upload()) | ||||||
|  | 		{ | ||||||
|  | 			$data['error'] = $this->upload->display_errors(); | ||||||
|  | 
 | ||||||
|  | 			$this->load->view('layout/header', $data); | ||||||
|  | 			$this->load->view('lotw/export'); | ||||||
|  | 			$this->load->view('layout/footer'); | ||||||
|  | 		} | ||||||
|  | 		else | ||||||
|  | 		{ | ||||||
|  | 
 | ||||||
|  | 			$data = array('upload_data' => $this->upload->data()); | ||||||
|  | 			 | ||||||
|  | 			// Curl stuff goes here
 | ||||||
|  | 			 | ||||||
|  | 			//unlink('./uploads/'.$data['upload_data']['file_name']);
 | ||||||
|  | 
 | ||||||
|  | 			$data['page_title'] = "LoTW .TQ8 Sent"; | ||||||
|  | 			$this->load->view('layout/header', $data); | ||||||
|  | 			 | ||||||
|  | 			//Perhaps return some sort of success page
 | ||||||
|  | 			$this->load->view('lotw/analysis'); | ||||||
|  | 			$this->load->view('layout/footer'); | ||||||
|  | 
 | ||||||
|  | 
 | ||||||
|  | 		} | ||||||
|  | 		 | ||||||
|  | 		 | ||||||
|  | 	} | ||||||
|  | 	 | ||||||
| } // end class
 | } // end class
 | ||||||
|  | @ -81,6 +81,7 @@ | ||||||
| 					<li><a href="<?php echo site_url('export');?>" title="Data Export">Data Export</a></li> | 					<li><a href="<?php echo site_url('export');?>" title="Data Export">Data Export</a></li> | ||||||
| 					<li><a href="<?php echo site_url('api/help');?>" title="API">API</a></li> | 					<li><a href="<?php echo site_url('api/help');?>" title="API">API</a></li> | ||||||
| 					<li><a href="<?php echo site_url('lotw/import');?>" title="LoTW Import">LoTW Import</a></li> | 					<li><a href="<?php echo site_url('lotw/import');?>" title="LoTW Import">LoTW Import</a></li> | ||||||
|  | 					<li><a href="<?php echo site_url('lotw/export');?>" title="LoTW Export">LoTW Export</a></li> | ||||||
| 				</ul> | 				</ul> | ||||||
| 			<?php } ?>
 | 			<?php } ?>
 | ||||||
|         	</ul> |         	</ul> | ||||||
|  |  | ||||||
|  | @ -0,0 +1,24 @@ | ||||||
|  | <div id="container"> | ||||||
|  | <h2><?php echo $page_title; ?></h2>
 | ||||||
|  | 
 | ||||||
|  | 	 | ||||||
|  | 	<h4>Step 1</h4> | ||||||
|  | 		<a href="<?php echo site_url('adif/export_lotw'); ?>" title="Export LoTW" target="_blank">Export an ADIF</a> file of QSOs that have not been uploaded to LoTW. | ||||||
|  | 		 | ||||||
|  | 	<h4>Step 2</h4> | ||||||
|  | 		<p>Use Trusted QSL to sign the exported file.</p> | ||||||
|  | 		 | ||||||
|  | 	<h4>Step 3</h4> | ||||||
|  | 		<p>Select the signed file and click "Upload". It will be sent to LoTW for processing.</p> | ||||||
|  | 			 | ||||||
|  | 	<?php echo form_open_multipart('lotw/export');?>
 | ||||||
|  | 		<p><span class="label important">Important</span> Log files must have the file type .tq8</p> | ||||||
|  | 		<input type="file" name="userfile" size="20" /> | ||||||
|  | 			 | ||||||
|  | 		<p>Cloudlog will use the LoTW username an password stored in your user profile to download a report from LoTW for you. The report Cloudlog downloads will have all confirmations since your last LoTW confirmation, up until now.</p> | ||||||
|  | 
 | ||||||
|  | 		<input class="btn primary" type="submit" value="Upload" /> | ||||||
|  | 	</form> | ||||||
|  | 
 | ||||||
|  | 
 | ||||||
|  | </div> | ||||||
		正在加载…
	
		在新工单中引用