Add DB column and edit/view functiions
这个提交包含在:
		
							父节点
							
								
									66f70af2c4
								
							
						
					
					
						当前提交
						59a3df06b6
					
				
					共有  5 个文件被更改,包括 40 次插入 和 2 次删除
				
			
		|  | @ -21,7 +21,7 @@ $config['migration_enabled'] = TRUE; | |||
| | be upgraded / downgraded to. | ||||
| | | ||||
| */ | ||||
| $config['migration_version'] = 95; | ||||
| $config['migration_version'] = 96; | ||||
| 
 | ||||
| /* | ||||
| |-------------------------------------------------------------------------- | ||||
|  |  | |||
|  | @ -0,0 +1,28 @@ | |||
| <?php | ||||
| 
 | ||||
| defined('BASEPATH') OR exit('No direct script access allowed'); | ||||
| 
 | ||||
| /** | ||||
|  * Class Migration_add_wwff_columns | ||||
|  * | ||||
|  * Add wWFF columnds to database | ||||
|  *  | ||||
|  */ | ||||
| 
 | ||||
| class Migration_add_wwff_columns extends CI_Migration { | ||||
| 
 | ||||
|         public function up() | ||||
|         { | ||||
|                 if (!$this->db->field_exists('COL_WWFF_REF', 'TABLE_HRD_CONTACTS_V01')) { | ||||
|                         $fields = array( | ||||
|                                 'COL_WWFF_REF VARCHAR(30) DEFAULT NULL', | ||||
|                         ); | ||||
|                         $this->dbforge->add_column('TABLE_HRD_CONTACTS_V01', $fields, 'COL_VUCC_GRIDS'); | ||||
|                 } | ||||
|         } | ||||
| 
 | ||||
|         public function down() | ||||
|         { | ||||
|                 $this->dbforge->drop_column('TABLE_HRD_CONTACTS_V01', 'COL_WWFF_REF'); | ||||
|         } | ||||
| } | ||||
|  | @ -177,6 +177,7 @@ class Logbook_model extends CI_Model { | |||
|             'COL_STATE' => trim($this->input->post('usa_state')), | ||||
|             'COL_CNTY' => $clean_county_input, | ||||
|             'COL_SOTA_REF' => trim($this->input->post('sota_ref')), | ||||
|             'COL_WWFF_REF' => trim($this->input->post('wwff_ref')), | ||||
|             'COL_SIG' => trim($this->input->post('sig')), | ||||
|             'COL_SIG_INFO' => trim($this->input->post('sig_info')), | ||||
|             'COL_DARC_DOK' => strtoupper(trim($darc_dok)), | ||||
|  | @ -661,6 +662,7 @@ class Logbook_model extends CI_Model { | |||
|        'COL_LOTW_QSL_RCVD' => $this->input->post('lotw_recv'), | ||||
|        'COL_IOTA' => $this->input->post('iota_ref'), | ||||
|        'COL_SOTA_REF' => $this->input->post('sota_ref'), | ||||
|        'COL_WWFF_REF' => $this->input->post('wwff_ref'), | ||||
|        'COL_TX_PWR' => $txpower, | ||||
|        'COL_SIG' => $this->input->post('sig'), | ||||
|        'COL_SIG_INFO' => $this->input->post('sig_info'), | ||||
|  | @ -2656,6 +2658,7 @@ class Logbook_model extends CI_Model { | |||
|                 'COL_SILENT_KEY' => (!empty($record['silent_key'])) ? $record['silent_key'] : '', | ||||
|                 'COL_SKCC' => (!empty($record['skcc'])) ? $record['skcc'] : '', | ||||
|                 'COL_SOTA_REF' => (!empty($record['sota_ref'])) ? $record['sota_ref'] : '', | ||||
|                 'COL_WWFF_REF' => (!empty($record['wwff_ref'])) ? $record['wwff_ref'] : '', | ||||
|                 'COL_SRX' => (!empty($record['srx'])) ? $record['srx'] : null, | ||||
|                 'COL_SRX_STRING' => (!empty($record['srx_string'])) ? $record['srx_string'] : '', | ||||
|                 'COL_STATE' => (!empty($record['state'])) ? strtoupper($record['state']) : '', | ||||
|  |  | |||
|  | @ -396,7 +396,7 @@ | |||
| 
 | ||||
|                                 <div class="form-group"> | ||||
|                                     <label for="wwff_ref">WWFF</label> | ||||
|                                     <input type="text" class="form-control" id="wwff_ref_edit" name="wwff_ref" value="<?php echo $qso->COL_SOTA_REF; ?>"> | ||||
|                                     <input type="text" class="form-control" id="wwff_ref_edit" name="wwff_ref" value="<?php echo $qso->COL_WWFF_REF; ?>"> | ||||
|                                 </div> | ||||
| 
 | ||||
|                                 <div class="form-group"> | ||||
|  |  | |||
|  | @ -208,6 +208,13 @@ | |||
|                     </tr> | ||||
|                     <?php } ?>
 | ||||
| 
 | ||||
|                     <?php if($row->COL_WWFF_REF != null) { ?>
 | ||||
|                     <tr> | ||||
|                         <td><?php echo $this->lang->line('gen_hamradio_wwff_reference'); ?></td>
 | ||||
|                         <td><a href="https://wwff.co/directory/?showRef=<?php echo $row->COL_WWFF_REF; ?>" target="_blank"><?php echo $row->COL_WWFF_REF; ?></a></td>
 | ||||
|                     </tr> | ||||
|                     <?php } ?>
 | ||||
| 
 | ||||
|                     <?php if($row->COL_SIG != null) { ?>
 | ||||
|                     <tr> | ||||
|                         <td><?php echo $this->lang->line('gen_hamradio_sig'); ?></td>
 | ||||
|  |  | |||
		正在加载…
	
		在新工单中引用