1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
|
L.ui.view.extend({
title: L.tr('Hostnames'),
description: L.tr('Manage static host records to let the local DNS server resolve certain names to specific IP addresses.'),
execute: function() {
var m = new L.cbi.Map('dhcp', {
readonly: !this.options.acls.hostnames
});
var s = m.section(L.cbi.TableSection, 'domain', {
anonymous: true,
addremove: true,
add_caption: L.tr('Add new hostname'),
remove_caption: L.tr('Remove hostname')
});
s.option(L.cbi.InputValue, 'name', {
caption: L.tr('Hostname'),
datatype: 'hostname'
});
s.option(L.cbi.InputValue, 'ip', {
caption: L.tr('IP address'),
datatype: 'ipaddr'
});
return m.insertInto('#map');
}
});
|