1 L
.network
.Protocol
.extend({
3 description
: L
.tr('DHCP client'),
7 populateForm: function(section
, iface
)
9 section
.taboption('general', L
.cbi
.InputValue
, 'hostname', {
10 caption
: L
.tr('Hostname'),
11 description
: L
.tr('Hostname to send when requesting DHCP'),
14 }).load = function() {
16 return L
.system
.getBoardInfo().then(function(info
) {
17 self
.options
.placeholder
= info
.hostname
;
21 section
.taboption('advanced', L
.cbi
.CheckboxValue
, 'broadcast', {
22 caption
: L
.tr('Use broadcast'),
23 description
: L
.tr('Required for certain ISPs, e.g. Charter with DOCSIS3'),
27 section
.taboption('advanced', L
.cbi
.CheckboxValue
, 'defaultroute', {
28 caption
: L
.tr('Use gateway'),
29 description
: L
.tr('Create default route via DHCP gateway'),
34 section
.taboption('advanced', L
.cbi
.CheckboxValue
, 'peerdns', {
35 caption
: L
.tr('Use DNS'),
36 description
: L
.tr('Use DNS servers advertised by DHCP'),
41 section
.taboption('advanced', L
.cbi
.DynamicList
, 'dns', {
42 caption
: L
.tr('Custom DNS'),
43 description
: L
.tr('Use custom DNS servers instead of DHCP ones'),
46 }).depends('peerdns', false);
48 section
.taboption('advanced', L
.cbi
.InputValue
, 'clientid', {
49 caption
: L
.tr('Client ID'),
50 description
: L
.tr('Client ID to send when requesting DHCP'),
54 section
.taboption('advanced', L
.cbi
.InputValue
, 'vendorid', {
55 caption
: L
.tr('Vendor Class'),
56 description
: L
.tr('Vendor Class to send when requesting DHCP'),