load->model('user_model');
// Check if users logged in
if ($this->user_model->validate_session() == 0) {
// user is not logged in
redirect('user/login');
}
session_write_close();
// load the view
$data['page_title'] = __("Hardware Interfaces");
$footerData = [];
$footerData['scripts'] = [
'assets/js/sections/radio.js',
];
$this->load->view('interface_assets/header', $data);
$this->load->view('radio/index');
$this->load->view('interface_assets/footer', $footerData);
}
function status() {
$this->load->model('user_model');
if(!$this->user_model->authorize(3)) { $this->session->set_flashdata('error', __("You're not allowed to do that!")); redirect('dashboard'); }
session_write_close();
$this->load->model('cat');
$query = $this->cat->status();
// Get the default radio
$default_user_radio = $this->user_options_model->get_options('cat', array('option_name' => $this->_get_optionname()), $this->_get_correct_uid())->row()->option_value ?? NULL;
if ($query->num_rows() > 0) {
echo "";
echo " " . __("Radio") . " ";
if ($this->session->userdata('clubstation') == 1 && clubaccess_check(9)) {
echo "" . __("Operator") . " ";
}
echo "" . __("Frequency") . " ";
echo "" . __("Mode") . " ";
echo "" . __("Timestamp") . " ";
echo " ";
echo "" . __("Options") . " ";
echo "" . __("Settings") . " ";
echo "";
echo "
" . __("You can still set a default radio using the WebSocket option.") . "
"; echo $websocket_button; echo "