Revision 35abdef2
Added by Christian McDonald almost 2 years ago
src/usr/local/www/js/pfSenseHelpers.js | ||
---|---|---|
782 | 782 |
|
783 | 783 |
// Once the AJAX call has returned, refresh the page to show the new service |
784 | 784 |
ajaxRequest.done(function (response, textStatus, jqXHR) { |
785 |
// location.reload(true); |
|
786 |
var loc = window.location; |
|
787 |
window.location = loc.protocol + '//' + loc.host + loc.pathname + loc.search; |
|
785 |
location.reload(true); |
|
788 | 786 |
}); |
789 | 787 |
}); |
790 | 788 |
|
src/usr/local/www/services_dhcp_relay.php | ||
---|---|---|
149 | 149 |
} |
150 | 150 |
} |
151 | 151 |
|
152 |
$pgtitle = array(gettext('Services'), gettext('DHCP Relay'));
|
|
153 |
$shortcut_section = 'dhcrelay';
|
|
154 |
include('head.inc');
|
|
152 |
$pgtitle = array(gettext("Services"), gettext("DHCP Relay"));
|
|
153 |
$shortcut_section = "dhcp";
|
|
154 |
include("head.inc");
|
|
155 | 155 |
|
156 | 156 |
if ($dhcpd_enabled) { |
157 |
print_info_box(gettext('DHCP Server is currently enabled. DHCP Relay cannot be enabled while the DHCP Server is enabled on any interface.'), 'danger', false); |
|
157 |
print_info_box(gettext("DHCP Server is currently enabled. Cannot enable the DHCP Relay service while the DHCP Server is enabled on any interface."), 'danger', false); |
|
158 |
include("foot.inc"); |
|
159 |
exit; |
|
158 | 160 |
} |
159 | 161 |
|
160 | 162 |
if ($input_errors) { |
... | ... | |
165 | 167 |
print_apply_result_box($retval); |
166 | 168 |
} |
167 | 169 |
|
168 |
$form = new Form(gettext('Save'), !$dhcpd_enabled);
|
|
170 |
$form = new Form; |
|
169 | 171 |
|
170 |
$section = new Form_Section(gettext('DHCP Relay Configuration'));
|
|
172 |
$section = new Form_Section('DHCP Relay Configuration');
|
|
171 | 173 |
|
172 |
$input = new Form_Checkbox(
|
|
174 |
$section->addInput(new Form_Checkbox(
|
|
173 | 175 |
'enable', |
174 |
gettext('Enable'),
|
|
175 |
gettext('Enable DHCP Relay'),
|
|
176 |
'Enable',
|
|
177 |
'Enable DHCP Relay on interface',
|
|
176 | 178 |
$pconfig['enable'] |
177 |
); |
|
178 |
|
|
179 |
if ($dhcpd_enabled) { |
|
180 |
$input->setAttribute('disabled', true); |
|
181 |
} |
|
182 |
|
|
183 |
$section->addInput($input); |
|
179 |
)); |
|
184 | 180 |
|
185 | 181 |
$section->addInput(new Form_Select( |
186 | 182 |
'interface', |
... | ... | |
234 | 230 |
|
235 | 231 |
$form->add($section); |
236 | 232 |
|
237 |
$button = new Form_Button(
|
|
233 |
$form->addGlobal(new Form_Button(
|
|
238 | 234 |
'addrow', |
239 |
gettext('Add server'),
|
|
235 |
"Add server",
|
|
240 | 236 |
null, |
241 | 237 |
'fa-plus' |
242 |
); |
|
243 |
$button->addClass('btn-success addbtn'); |
|
244 |
if ($dhcpd_enabled) { |
|
245 |
$button->setAttribute('disabled', true); |
|
246 |
} |
|
247 |
$form->addGlobal($button); |
|
238 |
))->addClass('btn-success addbtn'); |
|
248 | 239 |
|
249 | 240 |
print $form; |
250 | 241 |
?> |
src/usr/local/www/shortcuts.inc | ||
---|---|---|
178 | 178 |
$shortcuts['dhcp6']['status'] = "status_dhcpv6_leases.php"; |
179 | 179 |
$shortcuts['dhcp6']['service'] = "dhcpd"; |
180 | 180 |
|
181 |
$shortcuts['dhcrelay'] = array(); |
|
182 |
$shortcuts['dhcrelay']['main'] = 'services_dhcp_relay.php'; |
|
183 |
$shortcuts['dhcrelay']['log'] = 'status_logs.php?logfile=dhcpd'; |
|
184 |
$shortcuts['dhcrelay']['service'] = 'dhcrelay'; |
|
185 |
|
|
186 | 181 |
$shortcuts['radvd'] = array(); |
187 | 182 |
$shortcuts['radvd']['main'] = "services_router_advertisements.php"; |
188 | 183 |
$shortcuts['radvd']['log'] = "status_logs.php?logfile=routing"; |
Also available in: Unified diff
Revert "services_dhcp_relay.php: introduce proper shortcut section for dhcrelay"
This reverts commit 834bb946dd952f1d7a59e131d6b265cc82b7837d.