Add option to hide dashboard banner
这个提交包含在:
父节点
80f8b88c5a
当前提交
3f5a17db0b
共有 3 个文件被更改,包括 19 次插入 和 0 次删除
|
|
@ -90,6 +90,14 @@ class Options extends CI_Controller {
|
|||
$this->session->set_flashdata('success', 'Global Search changed to '.$this->input->post('globalSearch'));
|
||||
}
|
||||
|
||||
// Update dashboard banner within the options system
|
||||
$dasboard_banner_update_status = $this->optionslib->update('dashboard_banner', $this->input->post('dashboardBanner'), 'yes');
|
||||
|
||||
// If dashboard banner update is complete set a flashsession with a success note
|
||||
if($dasboard_banner_update_status == TRUE) {
|
||||
$this->session->set_flashdata('success', 'Dashboard banner changed to '.$this->input->post('dashboardBanner'));
|
||||
}
|
||||
|
||||
// Update Lang choice within the options system
|
||||
// $lang_update_status = $this->optionslib->update('language', $this->input->post('language'));
|
||||
|
||||
|
|
|
|||
|
|
@ -47,6 +47,7 @@ function echoQrbCalcLink($mygrid, $grid, $vucc) {
|
|||
<div class="container dashboard">
|
||||
<?php if(($this->config->item('use_auth') && ($this->session->userdata('user_type') >= 2)) || $this->config->item('use_auth') === FALSE) { ?>
|
||||
|
||||
<?php if($this->optionslib->get_option('dashboard_banner') != "false") { ?>
|
||||
<?php if($todays_qsos >= 1) { ?>
|
||||
<div class="alert alert-success" role="alert">
|
||||
<?php echo $this->lang->line('dashboard_you_have_had'); ?> <strong><?php echo $todays_qsos; ?></strong> <?php echo $this->lang->line('dashboard_qsos_today'); ?>
|
||||
|
|
@ -56,6 +57,7 @@ function echoQrbCalcLink($mygrid, $grid, $vucc) {
|
|||
<span class="badge badge-info"><?php echo $this->lang->line('general_word_important'); ?></span> <i class="fas fa-broadcast-tower"></i> <?php echo $this->lang->line('notice_turn_the_radio_on'); ?>
|
||||
</div>
|
||||
<?php } ?>
|
||||
<?php } ?>
|
||||
|
||||
<?php if($current_active == 0) { ?>
|
||||
<div class="alert alert-danger" role="alert">
|
||||
|
|
|
|||
|
|
@ -69,6 +69,15 @@
|
|||
<small id="globalSearchHelp" class="form-text text-muted">This allows non logged in users to access the search functions.</small>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label for="dashboardBanner">Dashboard Notification Banner</label>
|
||||
<select class="custom-select" id="dashboardBanner" name="dashboardBanner" aria-describedby="dashboardBannerHelp" required>
|
||||
<option value='true' <?php if($this->optionslib->get_option('dashboard_banner') == "true") { echo "selected=\"selected\""; } ?>>Enabled</option>
|
||||
<option value='false' <?php if($this->optionslib->get_option('dashboard_banner') == "false") { echo "selected=\"selected\""; } ?>>Disabled</option>
|
||||
</select>
|
||||
<small id="dashboardBannerHelp" class="form-text text-muted">This allows to disable the global notification banner on the dashboard.</small>
|
||||
</div>
|
||||
|
||||
<!-- Save the Form -->
|
||||
<input class="btn btn-primary" type="submit" value="Save" />
|
||||
</form>
|
||||
|
|
|
|||
正在加载…
在新工单中引用