Commit f2c21377 authored by Marius Burkard's avatar Marius Burkard
Browse files

Merge branch '5481-spf-button-admin' into 'develop'

Resolve "SPF modification error with user account"

Closes #5481

See merge request ispconfig/ispconfig3!1612
parents c7bde0cf f02fd397
......@@ -170,7 +170,7 @@ $form["tabs"]['dns'] = array (
)
);
if($_SESSION["s"]["user"]["typ"] == 'admin') {
if($app->auth->is_admin()) {
unset($form["tabs"]['dns']['fields']['data']['validators']);
$form["tabs"]['dns']['fields']['data']['validators'][0]['type'] = 'NOTEMPTY';
$form["tabs"]['dns']['fields']['data']['validators'][0]['errmsg'] = 'data_error_empty';
......
......@@ -53,7 +53,9 @@
<div class="clear"><div class="right">
<button class="btn btn-default formbutton-success" type="button" value="{tmpl_var name='btn_save_txt'}" data-submit-form="pageForm" data-form-action="dns/dns_spf_edit.php">{tmpl_var name='btn_save_txt'}</button>
<tmpl_if name="is_admin">
<button class="btn btn-default formbutton-default" type="button" value="{tmpl_var name='btn_edit_as_txt_record_txt'}" data-load-content="dns/dns_txt_edit.php?id={tmpl_var name='id'}&zone={tmpl_var name='zone'}&edit_raw=1">{tmpl_var name='btn_edit_as_txt_record_txt'}</button>
</tmpl_if>
<button class="btn btn-default formbutton-default" type="button" value="{tmpl_var name='btn_cancel_txt'}" data-load-content="dns/dns_soa_edit.php?id={tmpl_var name='zone'}&next_tab=dns_records">{tmpl_var name='btn_cancel_txt'}</button>
</div></div>
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment