kopia lustrzana https://github.com/magicbug/Cloudlog
Deleting a station profile also deletes all its associated QSOs
rodzic
a290fc5201
commit
81e8b51729
|
@ -73,6 +73,11 @@ class Stations extends CI_Model {
|
|||
// Clean ID
|
||||
$clean_id = $this->security->xss_clean($id);
|
||||
|
||||
// Delete QSOs
|
||||
$this->db->where('station_id', $id);
|
||||
$this->db->delete($this->config->item('table_name'));
|
||||
|
||||
// Delete Station Profile
|
||||
$this->db->delete('station_profile', array('station_id' => $clean_id));
|
||||
}
|
||||
|
||||
|
|
|
@ -70,7 +70,7 @@
|
|||
<a href="<?php echo site_url('station/edit')."/".$row->station_id; ?>" class="btn btn-info btn-sm"><i class="fas fa-edit-alt"></i> Edit</a>
|
||||
</td>
|
||||
<td>
|
||||
<a href="<?php echo site_url('station/delete')."/".$row->station_id; ?>" class="btn btn-danger btn-sm" onclick="return confirm('Are you sure you want delete QSO <?php echo $row->station_profile_name; ?>?');"><i class="fas fa-trash-alt"></i> Delete</a></td>
|
||||
<a href="<?php echo site_url('station/delete')."/".$row->station_id; ?>" class="btn btn-danger btn-sm" onclick="return confirm('Are you sure you want delete station profile <?php echo $row->station_profile_name; ?> this will delete all QSOs within this station profile?');"><i class="fas fa-trash-alt"></i> Delete</a></td>
|
||||
</tr>
|
||||
|
||||
<?php } ?>
|
||||
|
|
Ładowanie…
Reference in New Issue