luci2: move most RPC proxy function declarations into the views using them to reduce...
[project/luci2/ui.git] / luci2 / htdocs / luci2 / view / network.hosts.js
index 587b181ec4eb46b35d53fd9ed530801e5836f7ea..99fbe470a28fee8651bb886c37a79ab2cefcf504 100644 (file)
@@ -1,29 +1,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.'),
+       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
-        });
+       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')
-        });
+               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, 'name', {
+                       caption:     L.tr('Hostname'),
+                       datatype:    'hostname'
+               });
 
-        s.option(L.cbi.InputValue, 'ip', {
-            caption:     L.tr('IP address'),
-            datatype:    'ipaddr'
-        });
+               s.option(L.cbi.InputValue, 'ip', {
+                       caption:     L.tr('IP address'),
+                       datatype:    'ipaddr'
+               });
 
-        return m.insertInto('#map');
-    }
+               return m.insertInto('#map');
+       }
 });