mirror of
https://github.com/wavelog/wavelog.git
synced 2026-03-22 10:24:14 +00:00
26 lines
625 B
PHP
26 lines
625 B
PHP
<?php
|
|
|
|
class Stationsetup_model extends CI_Model {
|
|
|
|
function getContainer($id) {
|
|
// Clean ID
|
|
$clean_id = $this->security->xss_clean($id);
|
|
|
|
$this->db->where('user_id', $this->session->userdata('user_id'));
|
|
$this->db->where('logbook_id', $clean_id);
|
|
return $this->db->get('station_logbooks');
|
|
}
|
|
|
|
function saveContainer() {
|
|
$data = array(
|
|
'logbook_name' => xss_clean($this->input->post('name', true)),
|
|
);
|
|
|
|
$this->db->where('user_id', $this->session->userdata('user_id'));
|
|
$this->db->where('logbook_id', xss_clean($this->input->post('id', true)));
|
|
$this->db->update('station_logbooks', $data);
|
|
}
|
|
}
|
|
|
|
?>
|