Skip to content

Commit

Permalink
+ Added save dialog notice
Browse files Browse the repository at this point in the history
! Fixed an issue where standalone options didn't show up.

Signed-off-by: jdarwood007 <unmonitored+github@sleepycode.com>
  • Loading branch information
jdarwood007 committed Nov 28, 2015
1 parent f85df98 commit 1ebd168
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
3 changes: 3 additions & 0 deletions sd_source/SimpleDesk-Admin.php
Expand Up @@ -320,6 +320,7 @@ function shd_switchable_item(item, state)
}

saveDBSettings($save_vars);
$_SESSION['adm-save'] = true;
redirectexit('action=admin;area=helpdesk_options;sa=' . $_REQUEST['sa']);
}

Expand Down Expand Up @@ -560,6 +561,8 @@ function switchitems()
add_integration_function('integrate_fallback_action', 'shd_main', true, '$sourcedir/sd_source/SimpleDesk.php');
}
}

return $config_vars;
}

/**
Expand Down
7 changes: 7 additions & 0 deletions sd_template/SimpleDesk-Admin.template.php
Expand Up @@ -267,6 +267,13 @@ function template_shd_show_settings()
{
global $context, $txt, $settings, $scripturl;

if (!empty($context['saved_successful']))
echo '
<div class="infobox">', $txt['settings_saved'], '</div>';
elseif (!empty($context['saved_failed']))
echo '
<div class="errorbox">', sprintf($txt['settings_not_saved'], $context['saved_failed']), '</div>';

echo '
<script type="text/javascript"><!-- // --><![CDATA[
function invertList(state, id_list)
Expand Down

0 comments on commit 1ebd168

Please sign in to comment.