Added bootstrapdialog for DOK award.
这个提交包含在:
		
							父节点
							
								
									c06baf39e3
								
							
						
					
					
						当前提交
						7e7f5ce63e
					
				
					共有  4 个文件被更改,包括 70 次插入 和 1 次删除
				
			
		|  | @ -75,6 +75,41 @@ class Awards extends CI_Controller { | ||||||
| 		$this->load->view('interface_assets/footer'); | 		$this->load->view('interface_assets/footer'); | ||||||
| 	} | 	} | ||||||
| 
 | 
 | ||||||
|  |     public function dok_details_ajax(){ | ||||||
|  |         $a = $this->input->post(); | ||||||
|  |         $q = ""; | ||||||
|  |         foreach ($a as $key => $value) { | ||||||
|  |             $q .= $key."=".$value.("(and)"); | ||||||
|  |         } | ||||||
|  |         $q = substr($q, 0, strlen($q)-13); | ||||||
|  | 
 | ||||||
|  |         $arguments["query"] = $q; | ||||||
|  |         $arguments["fields"] = ''; | ||||||
|  |         $arguments["format"] = "json"; | ||||||
|  |         $arguments["limit"] = ''; | ||||||
|  |         $arguments["order"] = ''; | ||||||
|  | 
 | ||||||
|  |         // print_r($arguments);
 | ||||||
|  |         // return;
 | ||||||
|  | 
 | ||||||
|  |         // Load the API and Logbook models
 | ||||||
|  |         $this->load->model('api_model'); | ||||||
|  |         $this->load->model('logbook_model'); | ||||||
|  | 
 | ||||||
|  |         // Call the parser within the API model to build the query
 | ||||||
|  |         $query = $this->api_model->select_parse($arguments); | ||||||
|  | 
 | ||||||
|  |         // Execute the query, and retrieve the results
 | ||||||
|  |         $data = $this->logbook_model->api_search_query($query); | ||||||
|  | 
 | ||||||
|  |         // Render Page
 | ||||||
|  |         $data['page_title'] = "Log View - DOK"; | ||||||
|  |         $data['filter'] = str_replace("(and)", ", ", $q);//implode(", ", array_keys($a));
 | ||||||
|  |         //$this->load->view('interface_assets/header', $data);
 | ||||||
|  |         $this->load->view('awards/dok/details_ajax', $data); | ||||||
|  |         //$this->load->view('interface_assets/footer');
 | ||||||
|  |     } | ||||||
|  | 	 | ||||||
| 	public function dxcc ()	{ | 	public function dxcc ()	{ | ||||||
| 		$this->load->model('dxcc'); | 		$this->load->model('dxcc'); | ||||||
|         $data['worked_bands'] = $this->dxcc->get_worked_bands(); // Used in the view for band select
 |         $data['worked_bands'] = $this->dxcc->get_worked_bands(); // Used in the view for band select
 | ||||||
|  |  | ||||||
|  | @ -0,0 +1,3 @@ | ||||||
|  | <h3>Filtering on <?php echo $filter ?></h3>
 | ||||||
|  | 
 | ||||||
|  | <?php $this->load->view('view_log/partial/log_ajax') ?>
 | ||||||
|  | @ -26,7 +26,7 @@ | ||||||
| 	                if ($count == 0){ | 	                if ($count == 0){ | ||||||
| 	      	             print("<td> </td>"); | 	      	             print("<td> </td>"); | ||||||
| 	                }else{ | 	                }else{ | ||||||
| 	                    printf("<td><a href='dok_details?Dok=\"%s\"&Band=\"%s\"'>%d</a></td>", str_replace("&", "%26", $dok), $band, $count); | 	                    printf("<td><a href='javascript:displayDokContacts(\"%s\",\"%s\")'>%d</a></td>", str_replace("&", "%26", $dok), $band, $count); | ||||||
| 	                } | 	                } | ||||||
| 		}  | 		}  | ||||||
|             } |             } | ||||||
|  |  | ||||||
|  | @ -1486,6 +1486,37 @@ $(document).ready(function(){ | ||||||
| 
 | 
 | ||||||
|     <?php } ?>
 |     <?php } ?>
 | ||||||
| 
 | 
 | ||||||
|  | 
 | ||||||
|  |         <?php if ($this->uri->segment(2) == "dok") { ?>
 | ||||||
|  | 
 | ||||||
|  |         function displayDokContacts(dok, band) { | ||||||
|  |             var baseURL= "<?php echo base_url();?>"; | ||||||
|  |             $.ajax({ | ||||||
|  |                 url: baseURL + 'index.php/awards/dok_details_ajax', | ||||||
|  |                 type: 'post', | ||||||
|  |                 data: {'Dok': dok, | ||||||
|  |                     'Band': band | ||||||
|  |                 }, | ||||||
|  |                 success: function(html) { | ||||||
|  |                     BootstrapDialog.show({ | ||||||
|  |                         title: 'QSO Data', | ||||||
|  |                         size: BootstrapDialog.SIZE_WIDE, | ||||||
|  |                         cssClass: 'qso-dok-dialog', | ||||||
|  |                         nl2br: false, | ||||||
|  |                         message: html, | ||||||
|  |                         buttons: [{ | ||||||
|  |                             label: 'Close', | ||||||
|  |                             action: function (dialogItself) { | ||||||
|  |                                 dialogItself.close(); | ||||||
|  |                             } | ||||||
|  |                         }] | ||||||
|  |                     }); | ||||||
|  |                 } | ||||||
|  |             }); | ||||||
|  |         } | ||||||
|  | 
 | ||||||
|  |         <?php } ?>
 | ||||||
|  | 
 | ||||||
|         <?php if ($this->uri->segment(2) == "iota") { ?>
 |         <?php if ($this->uri->segment(2) == "iota") { ?>
 | ||||||
| 
 | 
 | ||||||
|         function displayIotaContacts(iota, band) { |         function displayIotaContacts(iota, band) { | ||||||
|  |  | ||||||
		正在加载…
	
		在新工单中引用