[% FOR config = data.config.options %]
[% IF config.type == 'text' %]
[% config.locale_text FILTER html %] :
[% IF data.module == 'cPanel' && config.name == 'host' %]
Generate a remote API token
[% END %]
[% ELSIF config.type == 'binary' %]
[% IF data.is_edit;
IF data.server.exists(config.name);
is_checked = data.server.${config.name};
ELSE;
# If the option isn't in the config, it is an action.
# Actions during edits should default to unchecked.
is_checked = 0;
END;
ELSE;
is_checked = config.default;
END;
%]
[% config.locale_text FILTER html %]
[% ELSIF config.type == 'radio' %]
[% config.locale_text FILTER html %]:
[%
SET set_value = data.server.${config.name} || config.default;
#Unsure of a way to make Template Toolkit do grep with \Q\E regexes
IF !set_value || !config.options.ofeach('value').grep("^$set_value$").size;
set_value = config.options.0.value;
END;
-%]
[% FOR option = config.options %]
[% SET is_checked = option.value == set_value -%]
[% option.label FILTER html %]
[% END # End foreach in radio options generations %]
[% ELSIF config.type == 'bigtext' %]
[% config.locale_text FILTER html %] :
[% ELSIF config.type == 'ip' %]
[% config.locale_text FILTER html %]
[% END -%]
[% END # End main loop -%]
[% locale.maketext("[asis,DNS] Role") %] :
[% SET dnsrole = data.server.dnsrole %]
[% PROCESS _dnsroles.tmpl %]
[% PROCESS _dnsroles_explained.tmpl %]