diff options
Diffstat (limited to 'applications')
62 files changed, 1674 insertions, 1375 deletions
diff --git a/applications/luci-app-adblock/luasrc/view/adblock/blocklist.htm b/applications/luci-app-adblock/luasrc/view/adblock/blocklist.htm index b4b62db5f4..424a72f6fd 100644 --- a/applications/luci-app-adblock/luasrc/view/adblock/blocklist.htm +++ b/applications/luci-app-adblock/luasrc/view/adblock/blocklist.htm @@ -51,37 +51,37 @@ table.cbi-section-table td, <%- end %> <div class="cbi-section-descr"><%=self.description%></div> <div class="cbi-section-node"> - <table class="cbi-section-table"> - <tr class="cbi-section-table-titles"> + <div class="table cbi-section-table"> + <div class="tr cbi-section-table-titles"> <%- if self.sectionhead then -%> - <th class="cbi-section-table-cell"><%=self.sectionhead%></th> + <div class="th cbi-section-table-cell"><%=self.sectionhead%></div> <%- else -%> - <th> </th> + <div class="th"> </div> <%- end -%> <%- for i, k in pairs(self.children) do -%> - <th class="cbi-section-table-cell"<%=width(k)%>> + <div class="th cbi-section-table-cell"<%=width(k)%>> <%-=k.title-%> - </th> + </div> <%- end -%> - </tr> + </div> <%- local isempty = true for i, k in ipairs(self:cfgsections()) do section = k isempty = false scope = { valueheader = "cbi/cell_valueheader", valuefooter = "cbi/cell_valuefooter" } -%> - <tr class="cbi-section-table-row" id="cbi-<%=self.config%>-<%=section%>"> - <th><%=k%></th> + <div class="tr cbi-section-table-row" id="cbi-<%=self.config%>-<%=section%>"> + <div class="th"><%=k%></div> <%- for k, node in ipairs(self.children) do node:render(section, scope or {}) end if not scope.cbid:match("adb_src_cat") then -%> - <td class="cbi-value-field"> </td> + <div class="td cbi-value-field"> </div> <%- end -%> - </tr> + </div> <%- end -%> - </table> + </div> </div> </fieldset> diff --git a/applications/luci-app-advanced-reboot/luasrc/view/advanced_reboot/advanced_reboot.htm b/applications/luci-app-advanced-reboot/luasrc/view/advanced_reboot/advanced_reboot.htm index 0629c84b36..5f7429dfd1 100644 --- a/applications/luci-app-advanced-reboot/luasrc/view/advanced_reboot/advanced_reboot.htm +++ b/applications/luci-app-advanced-reboot/luasrc/view/advanced_reboot/advanced_reboot.htm @@ -21,24 +21,24 @@ <%- if device_name then -%> <fieldset class="cbi-section"> <legend><%=device_name%><%: Partitions%></legend> - <table class="cbi-section-table" id="partitions"> - <tr class="cbi-section-table-titles"> - <th class="cbi-section-table-cell"><%:Partition%></th> - <th class="cbi-section-table-cell"><%:Status%></th> - <th class="cbi-section-table-cell"><%:Firmware/OS (Kernel)%></th> - <th class="cbi-section-table-cell"><%:Action%></th> - </tr> - <tr class="cbi-section-table-row"> - <td> + <div class="table cbi-section-table" id="partitions"> + <div class="tr cbi-section-table-titles"> + <div class="th cbi-section-table-cell"><%:Partition%></div> + <div class="th cbi-section-table-cell"><%:Status%></div> + <div class="th cbi-section-table-cell"><%:Firmware/OS (Kernel)%></div> + <div class="th cbi-section-table-cell"><%:Action%></div> + </div> + <div class="tr cbi-section-table-row"> + <div class="td"> <%=string.format("%X", boot_envvar1_partition_one)%> - </td> - <td> + </div> + <div class="td"> <%- if boot_envvar1_partition_one == current_partition then -%><%:Current%><%- else -%><%:Alternative%><%- end -%> - </td> - <td> + </div> + <div class="td"> <%=partition_one_os%> - </td> - <td> + </div> + <div class="td"> <%- if boot_envvar1_partition_one == current_partition then -%> <form method="post" action="<%=url('admin/system/advanced_reboot/reboot')%>"> <input type="hidden" name="token" value="<%=token%>" /> @@ -50,19 +50,19 @@ <input id="altreboot-button" type="submit" class="cbi-button cbi-button-apply" value="<%:Reboot to alternative partition...%>" /> </form> <%- end -%> - </td> - </tr> - <tr class="cbi-section-table-row"> - <td> + </div> + </div> + <div class="tr cbi-section-table-row"> + <div class="td"> <%=string.format("%X", boot_envvar1_partition_two)%> - </td> - <td> + </div> + <div class="td"> <%- if boot_envvar1_partition_two == current_partition then -%><%:Current%><%- else -%><%:Alternative%><%- end -%> - </td> - <td> + </div> + <div class="td"> <%=partition_two_os%> - </td> - <td> + </div> + <div class="td"> <%- if boot_envvar1_partition_two == current_partition then -%> <form method="post" action="<%=url('admin/system/advanced_reboot/reboot')%>"> <input type="hidden" name="token" value="<%=token%>" /> @@ -74,9 +74,9 @@ <input id="altreboot-button" type="submit" class="cbi-button cbi-button-apply" value="<%:Reboot to alternative partition...%>" /> </form> <%- end -%> - </td> - </tr> - </table> + </div> + </div> + </div> </fieldset> <%- else -%> <p class="alert-message warning"><%:Warning: This system does not have two partitions!%></p> diff --git a/applications/luci-app-ahcp/luasrc/view/ahcp_status.htm b/applications/luci-app-ahcp/luasrc/view/ahcp_status.htm index 946828953e..ab25f862b8 100644 --- a/applications/luci-app-ahcp/luasrc/view/ahcp_status.htm +++ b/applications/luci-app-ahcp/luasrc/view/ahcp_status.htm @@ -7,29 +7,21 @@ if (st && tb && tx) { /* clear all rows */ - while( tb.rows.length > 1 ) - tb.deleteRow(1); + while (tb.firstElementChild !== tb.lastElementChild) + tb.removeChild(tb.lastElementChild); - for( var i = 0; i < st.leases.length; i++ ) + for (var i = 0; i < st.leases.length; i++) { - var tr = tb.insertRow(-1); - tr.className = 'cbi-section-table-row cbi-rowstyle-' + ((i % 2) + 1); - - tr.insertCell(-1).innerHTML = st.leases[i].addr; - tr.insertCell(-1).innerHTML = String.format('%t', st.leases[i].age); + tb.appendChild(E('<div class="tr cbi-section-table-row cbi-rowstyle-%d">'.format((i % 2) + 1), [ + E('<div class="td">', st.leases[i].addr), + E('<div class="td">', '%t'.format(st.leases[i].age)) + ])); } - if( tb.rows.length == 1 ) - { - var tr = tb.insertRow(-1); - tr.className = 'cbi-section-table-row'; - - var td = tr.insertCell(-1); - td.colSpan = 2; - td.innerHTML = '<em><br /><%:There are no active leases.%></em>'; - } + if (tb.firstElementChild === tb.lastElementChild) + tb.appendChild(E('<div class="tr cbi-section-table-row"><div class="td"><em><br /><%:There are no active leases.%></em></div></div>')); - if( st.uid == '00:00:00:00:00:00:00:00' ) + if (st.uid == '00:00:00:00:00:00:00:00') tx.innerHTML = '<%:The AHCP Service is not running.%>'; else tx.innerHTML = String.format('<%:The AHCP Service is running with ID %s.%>', st.uid); @@ -41,13 +33,13 @@ <fieldset class="cbi-section"> <legend><%:Active AHCP Leases%></legend> <p id="ahcpd_status_text"></p> - <table class="cbi-section-table" id="ahcpd_status_table"> - <tr class="cbi-section-table-titles"> - <th class="cbi-section-table-cell"><%:Address%></th> - <th class="cbi-section-table-cell"><%:Age%></th> - </tr> - <tr class="cbi-section-table-row"> - <td colspan="5"><em><br /><%:Collecting data...%></em></td> - </tr> - </table> + <div class="table cbi-section-table" id="ahcpd_status_table"> + <div class="tr cbi-section-table-titles"> + <div class="th cbi-section-table-cell"><%:Address%></div> + <div class="th cbi-section-table-cell"><%:Age%></div> + </div> + <div class="tr cbi-section-table-row"> + <div class="td" colspan="5"><em><br /><%:Collecting data...%></em></div> + </div> + </div> </fieldset> diff --git a/applications/luci-app-asterisk/luasrc/view/asterisk/dialplans.htm b/applications/luci-app-asterisk/luasrc/view/asterisk/dialplans.htm index 9f644ba074..fb40335f99 100644 --- a/applications/luci-app-asterisk/luasrc/view/asterisk/dialplans.htm +++ b/applications/luci-app-asterisk/luasrc/view/asterisk/dialplans.htm @@ -79,23 +79,23 @@ <% for i, plan in pairs(ast.dialplan.plans()) do %> <div class="cbi-section-node"> - <table class="cbi-section-table"> - <tr class="cbi-section-table-titles"> - <th style="text-align: left; padding: 3px" class="cbi-section-table-cell"> + <div class="table cbi-section-table"> + <div class="tr cbi-section-table-titles"> + <div style="text-align: left; padding: 3px" class="th cbi-section-table-cell"> <big>Dialplan <em><%=plan.name%></em></big> - </th> - <td> + </div> + <div class="td"> <a href="<%=url('admin/asterisk/dialplans')%>?delplan=<%=plan.name%>"> <img style="border:none" alt="Remove this dialplan" title="Remove this dialplan" src="/luci-static/resources/cbi/remove.gif" /> </a> - </td> - </tr> + </div> + </div> <!-- dialzones --> <% local zones_used = { }; local row = 0 %> <% for i, zone in ipairs(plan.zones) do zones_used[zone.name] = true %> - <tr class="cbi-section-table-row <%=rowstyle(row)%>"> - <td style="text-align: left; padding: 3px" class="cbi-section-table-cell"> + <div class="tr cbi-section-table-row <%=rowstyle(row)%>"> + <div style="text-align: left; padding: 3px" class="td cbi-section-table-cell"> <strong>└ Dialzone <em><%=zone.name%></em></strong> (<%=zone.description%>) <p style="padding-left: 1em; margin-bottom:0"> Lines: @@ -107,24 +107,24 @@ Matches: <%=format_matches(zone)%> </p> - </td> - <td style="width:5%" class="cbi-value-field"> + </div> + <div style="width:5%" class="td cbi-value-field"> <a href="<%=url('admin/asterisk/dialplans/out', zone.name)%>"> <img style="border:none" alt="Edit dialzone" title="Edit dialzone" src="/luci-static/resources/cbi/edit.gif" /> </a> <a href="<%=url('admin/asterisk/dialplans')%>?delzone.<%=plan.name%>=<%=zone.name%>"> <img style="border:none" alt="Remove from this dialplan" title="Remove from this dialplan" src="/luci-static/resources/cbi/remove.gif" /> </a> - </td> - </tr> + </div> + </div> <% row = row + 1; end %> <!-- /dialzones --> <!-- voicemail --> <% local boxes_used = { } %> <% for ext, box in luci.util.kspairs(plan.voicemailboxes) do boxes_used[box.id] = true %> - <tr class="cbi-section-table-row <%=rowstyle(row)%>"> - <td style="text-align: left; padding: 3px" class="cbi-section-table-cell"> + <div class="tr cbi-section-table-row <%=rowstyle(row)%>"> + <div style="text-align: left; padding: 3px" class="td cbi-section-table-cell"> <strong>└ Voicemailbox <em><%=box.id%></em></strong> (<%=box.name%>) <p style="padding-left: 1em; margin-bottom:0"> Owner: <%=box.name%> | @@ -132,44 +132,44 @@ Pager: <%=#box.page > 0 and box.page or 'n/a'%><br /> Matches: <%=format_matches(ext)%> </p> - </td> - <td style="width:5%" class="cbi-value-field"> + </div> + <div style="width:5%" class="td cbi-value-field"> <a href="<%=url('admin/asterisk/voicemail/mailboxes')%>"> <img style="border:none" alt="Manage mailboxes ..." title="Manage mailboxes ..." src="/luci-static/resources/cbi/edit.gif" /> </a> <a href="<%=url('admin/asterisk/dialplans')%>?delvbox.<%=plan.name%>=<%=ext%>"> <img style="border:none" alt="Remove from this dialplan" title="Remove from this dialplan" src="/luci-static/resources/cbi/remove.gif" /> </a> - </td> - </tr> + </div> + </div> <% row = row + 1; end %> <!-- /voicemail --> <!-- meetme --> <% local rooms_used = { } %> <% for ext, room in luci.util.kspairs(plan.meetmerooms) do rooms_used[room.room] = true %> - <tr class="cbi-section-table-row <%=rowstyle(row)%>"> - <td style="text-align: left; padding: 3px" class="cbi-section-table-cell"> + <div class="tr cbi-section-table-row <%=rowstyle(row)%>"> + <div style="text-align: left; padding: 3px" class="td cbi-section-table-cell"> <strong>└ MeetMe Room <em><%=room.room%></em></strong> <% if room.description and #room.description > 0 then %> (<%=room.description%>)<% end %> <p style="padding-left: 1em; margin-bottom:0"> Matches: <%=format_matches(ext)%> </p> - </td> - <td style="width:5%" class="cbi-value-field"> + </div> + <div style="width:5%" class="td cbi-value-field"> <a href="<%=url('admin/asterisk/meetme/rooms')%>"> <img style="border:none" alt="Manage conferences ..." title="Manage conferences ..." src="/luci-static/resources/cbi/edit.gif" /> </a> <a href="<%=url('admin/asterisk/dialplans')%>?delmeetme.<%=plan.name%>=<%=ext%>"> <img style="border:none" alt="Remove from this dialplan" title="Remove from this dialplan" src="/luci-static/resources/cbi/remove.gif" /> </a> - </td> - </tr> + </div> + </div> <% row = row + 1; end %> <!-- /meetme --> - <tr class="cbi-section-table-row"> - <td style="text-align: left; padding: 3px" class="cbi-section-table-cell" colspan="2"> + <div class="tr cbi-section-table-row"> + <div style="text-align: left; padding: 3px" class="td cbi-section-table-cell" colspan="2"> <hr style="margin-bottom:0.5em; border-width:0 0 1px 0" /> Add Dialzone:<br /> @@ -213,10 +213,10 @@ <br /><br /> <input type="submit" class="cbi-button cbi-button-add" value="Add item »" title="Add item ..."/> - </td> - </tr> + </div> + </div> - </table> + </div> <div class="cbi-section-create cbi-tblsection-create"></div> </div> diff --git a/applications/luci-app-asterisk/luasrc/view/asterisk/dialzones.htm b/applications/luci-app-asterisk/luasrc/view/asterisk/dialzones.htm index ffdbbcf359..e48da608a6 100644 --- a/applications/luci-app-asterisk/luasrc/view/asterisk/dialzones.htm +++ b/applications/luci-app-asterisk/luasrc/view/asterisk/dialzones.htm @@ -66,59 +66,59 @@ <!-- tblsection --> <fieldset class="cbi-section" id="cbi-asterisk-sip"> <div class="cbi-section-node"> - <table class="cbi-section-table"> - <tr class="cbi-section-table-titles"> - <th style="text-align: left; padding: 3px" class="cbi-section-table-cell" colspan="6"> + <div class="table cbi-section-table"> + <div class="tr cbi-section-table-titles"> + <div style="text-align: left; padding: 3px" class="th cbi-section-table-cell" colspan="6"> <h3>Dialzone Overview</h3> - </th> - </tr> - - <tr class="cbi-section-table-descr"> - <th style="width: 5%; text-align:right" class="cbi-section-table-cell">Name</th> - <th style="width: 5%; text-align:right" class="cbi-section-table-cell">Prepend</th> - <th style="width: 20%; text-align:left" class="cbi-section-table-cell">- Match</th> - <th style="text-align:left" class="cbi-section-table-cell">Trunk</th> - <th style="width: 35%; text-align:left" class="cbi-section-table-cell">Description</th> - <th style="width: 4%; text-align:left" class="cbi-section-table-cell"></th> - </tr> + </div> + </div> + + <div class="tr cbi-section-table-descr"> + <div style="width: 5%; text-align:right" class="th cbi-section-table-cell">Name</div> + <div style="width: 5%; text-align:right" class="th cbi-section-table-cell">Prepend</div> + <div style="width: 20%; text-align:left" class="th cbi-section-table-cell">- Match</div> + <div style="text-align:left" class="th cbi-section-table-cell">Trunk</div> + <div style="width: 35%; text-align:left" class="th cbi-section-table-cell">Description</div> + <div style="width: 4%; text-align:left" class="th cbi-section-table-cell"></div> + </div> <% for i, rule in pairs(ast.dialzone.zones()) do %> - <tr class="cbi-section-table-row <%=rowstyle(i)%>"> - <td style="text-align:right" class="cbi-value-field"> + <div class="tr cbi-section-table-row <%=rowstyle(i)%>"> + <div style="text-align:right" class="td cbi-value-field"> <%=rule.name%> - </td> - <td style="text-align:right" class="cbi-value-field"> + </div> + <div style="text-align:right" class="td cbi-value-field"> <% for _ in ipairs(rule.matches) do %> <%=rule.addprefix and digit_pattern(rule.addprefix)%> <br /> <% end %> - </td> - <td style="text-align:left" class="cbi-value-field"> + </div> + <div style="text-align:left" class="td cbi-value-field"> <% for _, m in ipairs(rule.matches) do %> <%=rule.localprefix and "%s " % digit_pattern(rule.localprefix)%> <%=digit_pattern(m)%><br /> <% end %> - </td> - <td style="text-align:left" class="cbi-value-field"> + </div> + <div style="text-align:left" class="td cbi-value-field"> <%=ast.tools.hyperlinks( rule.trunks, function(v) return luci.dispatcher.build_url("admin", "asterisk", "trunks", "%s") % v:lower() end )%> - </td> - <td style="text-align:left" class="cbi-value-field"> + </div> + <div style="text-align:left" class="td cbi-value-field"> <%=rule.description or rule.name%> - </td> - <td style="text-align:left" class="cbi-value-field"> + </div> + <div style="text-align:left" class="td cbi-value-field"> <a href="<%=url('admin/asterisk/dialplans/out', rule.name)%>"> <img style="border:none" alt="Edit entry" title="Edit entry" src="/luci-static/resources/cbi/edit.gif" /> </a> <a href="<%=url('admin/asterisk/dialplans/zones')%>?delzone=<%=rule.name%>"> <img style="border:none" alt="Delete entry" title="Delete entry" src="/luci-static/resources/cbi/remove.gif" /> </a> - </td> - </tr> + </div> + </div> <% end %> - </table> + </div> <div class="cbi-section-create cbi-tblsection-create"></div> </div> <br /> @@ -133,26 +133,26 @@ <br /><span style="color:red">Invalid name given!</span><br /> <% end -%> - <table> - <tr> - <td style="padding:3px"> + <div class="table"> + <div class="tr"> + <div class="td" style="padding:3px"> <label for="create1">1) Name</label><br /> <input type="text" class="cbi-section-create-name" id="create1" name="newzone_name" style="width:200px" /> <br /><br /> <label for="create2">2) Number Match</label><br /> <input type="text" class="cbi-section-create-name" id="create2" name="newzone_match" style="width:200px" /> - </td> - <td style="padding:3px"> + </div> + <div class="td" style="padding:3px"> <label for="create3">3) Trunks</label><br /> <select class="cbi-input-select" multiple="multiple" id="create3" name="newzone_uses" size="4" style="width:200px"> <% for i, t in ipairs(find_trunks()) do %> <option value="<%=t[1]%>"><%=t[2]%></option> <% end %> </select> - </td> - </tr> - </table> + </div> + </div> + </div> <br /> <input type="submit" class="cbi-button cbi-button-add" name="newzone" value="Add entry" title="Add entry"/> diff --git a/applications/luci-app-firewall/luasrc/model/cbi/firewall/zones.lua b/applications/luci-app-firewall/luasrc/model/cbi/firewall/zones.lua index 500e5078f4..2c5083a019 100644 --- a/applications/luci-app-firewall/luasrc/model/cbi/firewall/zones.lua +++ b/applications/luci-app-firewall/luasrc/model/cbi/firewall/zones.lua @@ -3,6 +3,7 @@ local ds = require "luci.dispatcher" local fw = require "luci.model.firewall" +local fs = require "nixio.fs" local m, s, o, p, i, v @@ -32,6 +33,28 @@ for i, v in ipairs(p) do v:value("ACCEPT", translate("accept")) end +-- Netfilter flow offload support + +local offload = fs.access("/sys/module/xt_FLOWOFFLOAD/refcnt") + +if offload then + s:option(DummyValue, "offload_advice", + translate("Routing/NAT Offloading"), + translate("Experimental feature. Not fully compatible with QoS/SQM.")) + + o = s:option(Flag, "flow_offloading", + translate("Software flow offloading"), + translate("Software based offloading for routing/NAT")) + o.optional = true + + o = s:option(Flag, "flow_offloading_hw", + translate("Hardware flow offloading"), + translate("Requires hardware NAT support. Implemented at least for mt7621")) + o.optional = true + o:depends( "flow_offloading", 1) +end + +-- Firewall zones s = m:section(TypedSection, "zone", translate("Zones")) s.template = "cbi/tblsection" diff --git a/applications/luci-app-firewall/luasrc/view/firewall/cbi_addforward.htm b/applications/luci-app-firewall/luasrc/view/firewall/cbi_addforward.htm index b3079f3a48..279b6e06d6 100644 --- a/applications/luci-app-firewall/luasrc/view/firewall/cbi_addforward.htm +++ b/applications/luci-app-firewall/luasrc/view/firewall/cbi_addforward.htm @@ -20,58 +20,58 @@ -%> <div class="cbi-section-create cbi-tblsection-create"> <br /> - <table class="cbi-section-table" style="width:810px; margin-left:5px"> - <tr class="cbi-section-table-titles"> - <th class="cbi-section-table-cell" colspan="8"><%:New port forward%>:</th> - </tr> - <tr class="cbi-section-table-descr"> - <th class="cbi-section-table-cell"><%:Name%></th> - <th class="cbi-section-table-cell"><%:Protocol%></th> - <th class="cbi-section-table-cell"><%:External zone%></th> - <th class="cbi-section-table-cell"><%:External port%></th> - <th class="cbi-section-table-cell"><%:Internal zone%></th> - <th class="cbi-section-table-cell"><%:Internal IP address%></th> - <th class="cbi-section-table-cell"><%:Internal port%></th> - <th class="cbi-section-table-cell"></th> - </tr> - <tr class="cbi-section-table-row"> - <td class="cbi-section-table-cell"> + <div class="table cbi-section-table" style="width:810px; margin-left:5px"> + <div class="tr cbi-section-table-titles"> + <div class="th cbi-section-table-cell" colspan="8"><%:New port forward%>:</div> + </div> + <div class="tr cbi-section-table-descr"> + <div class="th cbi-section-table-cell"><%:Name%></div> + <div class="th cbi-section-table-cell"><%:Protocol%></div> + <div class="th cbi-section-table-cell"><%:External zone%></div> + <div class="th cbi-section-table-cell"><%:External port%></div> + <div class="th cbi-section-table-cell"><%:Internal zone%></div> + <div class="th cbi-section-table-cell"><%:Internal IP address%></div> + <div class="th cbi-section-table-cell"><%:Internal port%></div> + <div class="th cbi-section-table-cell"></div> + </div> + <div class="tr cbi-section-table-row"> + <div class="td cbi-section-table-cell"> <input type="text" class="cbi-input-text" id="_newfwd.name" name="_newfwd.name" placeholder="<%:New port forward%>" /> - </td> - <td class="cbi-section-table-cell" style="width:110px"> + </div> + <div class="td cbi-section-table-cell" style="width:110px"> <select class="cbi-input-select" id="_newfwd.proto" name="_newfwd.proto"> <option value="tcp udp">TCP+UDP</option> <option value="tcp">TCP</option> <option value="udp">UDP</option> <option value="other"><%:Other...%></option> </select> - </td> - <td class="cbi-section-table-cell" style="width:55px"> + </div> + <div class="td cbi-section-table-cell" style="width:55px"> <select class="cbi-input-select" id="_newfwd.extzone" name="_newfwd.extzone"> <% for _, z in ipairs(ezl) do -%><option value="<%=z:name()%>"><%=z:name()%></option><%- end %> </select> - </td> - <td class="cbi-section-table-cell" style="width:110px"> + </div> + <div class="td cbi-section-table-cell" style="width:110px"> <input type="text" class="cbi-input-text" id="_newfwd.extport" name="_newfwd.extport" data-type="portrange" data-optional="true" /> - </td> - <td class="cbi-section-table-cell" style="width:55px"> + </div> + <div class="td cbi-section-table-cell" style="width:55px"> <select class="cbi-input-select" id="_newfwd.intzone" name="_newfwd.intzone"> <% for _, z in ipairs(izl) do -%><option value="<%=z:name()%>"><%=z:name()%></option><%- end %> </select> - </td> - <td class="cbi-section-table-cell" style="width:110px"> + </div> + <div class="td cbi-section-table-cell" style="width:110px"> <input type="text" class="cbi-input-text" id="_newfwd.intaddr" name="_newfwd.intaddr" data-type="host" data-optional="true"<%= ifattr(#keys > 0, "data-choices", {keys, vals}) %>/> - </td> - <td class="cbi-section-table-cell" style="width:110px"> + </div> + <div class="td cbi-section-table-cell" style="width:110px"> <input type="text" class="cbi-input-text" id="_newfwd.intport" name="_newfwd.intport" data-type="portrange" data-optional="true" /> - </td> - <td class="cbi-section-table-cell"> + </div> + <div class="td cbi-section-table-cell"> <input type="submit" class="cbi-button cbi-button-add" name="cbi.cts.<%=self.config%>.<%=self.sectiontype%>.<%=section%>" value="<%:Add%>" /> - </td> - </tr> - </table> + </div> + </div> + </div> <script type="text/javascript">//<![CDATA[ cbi_bind(document.getElementById('_newfwd.extport'), 'blur', diff --git a/applications/luci-app-firewall/luasrc/view/firewall/cbi_addrule.htm b/applications/luci-app-firewall/luasrc/view/firewall/cbi_addrule.htm index b06fac3de4..c99ecaca37 100644 --- a/applications/luci-app-firewall/luasrc/view/firewall/cbi_addrule.htm +++ b/applications/luci-app-firewall/luasrc/view/firewall/cbi_addrule.htm @@ -8,71 +8,71 @@ <div class="cbi-section-create cbi-tblsection-create"> <% if wz then %> <br /> - <table class="cbi-section-table" style="margin-left:5px"> - <tr class="cbi-section-table-titles"> - <th class="cbi-section-table-cell left" colspan="4"><%:Open ports on router%>:</th> - </tr> - <tr class="cbi-section-table-descr"> - <th class="cbi-section-table-cell"><%:Name%></th> - <th class="cbi-section-table-cell"><%:Protocol%></th> - <th class="cbi-section-table-cell"><%:External port%></th> - <th class="cbi-section-table-cell"></th> - </tr> - <tr class="cbi-section-table-row"> - <td class="cbi-section-table-cell" style="width:130px"> + <div class="table cbi-section-table" style="margin-left:5px"> + <div class="tr cbi-section-table-titles"> + <div class="th cbi-section-table-cell left" colspan="4"><%:Open ports on router%>:</div> + </div> + <div class="tr cbi-section-table-descr"> + <div class="th cbi-section-table-cell"><%:Name%></div> + <div class="th cbi-section-table-cell"><%:Protocol%></div> + <div class="th cbi-section-table-cell"><%:External port%></div> + <div class="th cbi-section-table-cell"></div> + </div> + <div class="tr cbi-section-table-row"> + <div class="td cbi-section-table-cell" style="width:130px"> <input type="text" class="cbi-input-text" id="_newopen.name" name="_newopen.name" placeholder="<%:New input rule%>" /> - </td> - <td class="cbi-section-table-cell" style="width:110px"> + </div> + <div class="td cbi-section-table-cell" style="width:110px"> <select class="cbi-input-select" id="_newopen.proto" name="_newopen.proto"> <option value="tcp udp">TCP+UDP</option> <option value="tcp">TCP</option> <option value="udp">UDP</option> <option value="other"><%:Other...%></option> </select> - </td> - <td class="cbi-section-table-cell" style="width:110px"> + </div> + <div class="td cbi-section-table-cell" style="width:110px"> <input type="text" class="cbi-input-text" id="_newopen.extport" name="_newopen.extport" /> - </td> - <td class="cbi-section-table-cell left"> + </div> + <div class="td cbi-section-table-cell left"> <input type="submit" class="cbi-button cbi-button-add" name="_newopen.submit" value="<%:Add%>" /> - </td> - </tr> - </table> + </div> + </div> + </div> <% end %> <% if #zones > 1 then %> - <table class="cbi-section-table" style="margin-left:5px"> - <tr class="cbi-section-table-titles"> - <th class="cbi-section-table-cell left" colspan="6"><br /><%:New forward rule%>:</th> - </tr> - <tr class="cbi-section-table-descr"> - <th class="cbi-section-table-cell"><%:Name%></th> - <th class="cbi-section-table-cell"><%:Source zone%></th> - <th class="cbi-section-table-cell"><%:Destination zone%></th> - <th class="cbi-section-table-cell"></th> - </tr> - <tr class="cbi-section-table-row"> - <td class="cbi-section-table-cell" style="width:130px"> + <div class="table cbi-section-table" style="margin-left:5px"> + <div class="tr cbi-section-table-titles"> + <div class="th cbi-section-table-cell left" colspan="6"><br /><%:New forward rule%>:</div> + </div> + <div class="tr cbi-section-table-descr"> + <div class="th cbi-section-table-cell"><%:Name%></div> + <div class="th cbi-section-table-cell"><%:Source zone%></div> + <div class="th cbi-section-table-cell"><%:Destination zone%></div> + <div class="th cbi-section-table-cell"></div> + </div> + <div class="tr cbi-section-table-row"> + <div class="td cbi-section-table-cell" style="width:130px"> <input type="text" class="cbi-input-text" id="_newfwd.name" name="_newfwd.name" placeholder="<%:New forward rule%>" /> - </td> - <td class="cbi-section-table-cell" style="width:110px"> + </div> + <div class="td cbi-section-table-cell" style="width:110px"> <select class="cbi-input-text" id="_newfwd.src" name="_newfwd.src"> <% local k, v; for k, v in ipairs(fw:get_zones()) do -%> <option<%=ifattr(v:name() == "wan", "selected", "selected")%> value="<%=v:name()%>"><%=v:name()%></option> <%- end %> </select> - </td> - <td class="cbi-section-table-cell" style="width:110px"> + </div> + <div class="td cbi-section-table-cell" style="width:110px"> <select class="cbi-input-text" id="_newfwd.dest" name="_newfwd.dest"> <% local k, v; for k, v in ipairs(fw:get_zones()) do -%> <option<%=ifattr(v:name() == "lan", "selected", "selected")%> value="<%=v:name()%>"><%=v:name()%></option> <%- end %> </select> - </td> - <td class="cbi-section-table-cell left"> + </div> + <div class="td cbi-section-table-cell left"> <input type="submit" class="cbi-button cbi-button-link" name="_newfwd.submit" value="<%:Add and edit...%>" /> - </td> - </tr> - </table> + </div> + </div> + </div> <% else %> <input type="submit" class="cbi-button cbi-button-add" name="cbi.cts.<%=self.config%>.<%=self.sectiontype%>.<%=section%>" value="<%:Add%>" /> <% end %> diff --git a/applications/luci-app-firewall/luasrc/view/firewall/cbi_addsnat.htm b/applications/luci-app-firewall/luasrc/view/firewall/cbi_addsnat.htm index 0a5913fc00..b2775cf694 100644 --- a/applications/luci-app-firewall/luasrc/view/firewall/cbi_addsnat.htm +++ b/applications/luci-app-firewall/luasrc/view/firewall/cbi_addsnat.htm @@ -15,49 +15,49 @@ <div class="cbi-section-create cbi-tblsection-create"> <% if #zones > 1 then %> <br /> - <table class="cbi-section-table" style="width:700px; margin-left:5px"> - <tr class="cbi-section-table-titles"> - <th class="cbi-section-table-cell left" colspan="6"><%:New source NAT%>:</th> - </tr> - <tr class="cbi-section-table-descr"> - <th class="cbi-section-table-cell"><%:Name%></th> - <th class="cbi-section-table-cell"><%:Source zone%></th> - <th class="cbi-section-table-cell"><%:Destination zone%></th> - <th class="cbi-section-table-cell"><%:To source IP%></th> - <th class="cbi-section-table-cell"><%:To source port%></th> - <th class="cbi-section-table-cell"></th> - </tr> - <tr class="cbi-section-table-row"> - <td class="cbi-section-table-cell"> + <div class="table cbi-section-table" style="width:700px; margin-left:5px"> + <div class="tr cbi-section-table-titles"> + <div class="th cbi-section-table-cell left" colspan="6"><%:New source NAT%>:</div> + </div> + <div class="tr cbi-section-table-descr"> + <div class="th cbi-section-table-cell"><%:Name%></div> + <div class="th cbi-section-table-cell"><%:Source zone%></div> + <div class="th cbi-section-table-cell"><%:Destination zone%></div> + <div class="th cbi-section-table-cell"><%:To source IP%></div> + <div class="th cbi-section-table-cell"><%:To source port%></div> + <div class="th cbi-section-table-cell"></div> + </div> + <div class="tr cbi-section-table-row"> + <div class="td cbi-section-table-cell"> <input type="text" class="cbi-input-text" id="_newsnat.name" name="_newsnat.name" placeholder="<%:New SNAT rule%>" /> - </td> - <td class="cbi-section-table-cell" style="width:110px"> + </div> + <div class="td cbi-section-table-cell" style="width:110px"> <select class="cbi-input-text" id="_newsnat.src" name="_newsnat.src"> <% local k, v; for k, v in ipairs(fw:get_zones()) do -%> <option<%=ifattr(v:name() == "lan", "selected", "selected")%> value="<%=v:name()%>"><%=v:name()%></option> <%- end %> </select> - </td> - <td class="cbi-section-table-cell" style="width:110px"> + </div> + <div class="td cbi-section-table-cell" style="width:110px"> <select class="cbi-input-text" id="_newsnat.dest" name="_newsnat.dest"> <% local k, v; for k, v in ipairs(fw:get_zones()) do -%> <option<%=ifattr(v:name() == "wan", "selected", "selected")%> value="<%=v:name()%>"><%=v:name()%></option> <%- end %> </select> - </td> - <td class="cbi-section-table-cell" style="width:110px"> + </div> + <div class="td cbi-section-table-cell" style="width:110px"> <input type="text" class="cbi-input-text" id="_newsnat.dip" name="_newsnat.dip" placeholder="<%:Do not rewrite%>" data-type="ip4addr" data-optional="true"<%= ifattr(#keys > 0, "data-choices", { keys, vals }) %> /> - </td> - <td class="cbi-section-table-cell" style="width:110px"> + </div> + <div class="td cbi-section-table-cell" style="width:110px"> <input type="text" class="cbi-input-text" id="_newsnat.dport" name="_newsnat.dport" placeholder="<%:Do not rewrite%>" data-type="portrange" data-optional="true" /> - </td> - <td class="cbi-section-table-cell"> + </div> + <div class="td cbi-section-table-cell"> <input type="submit" class="cbi-button cbi-button-link" name="_newsnat.submit" value="<%:Add and edit...%>" /> - </td> - </tr> - </table> + </div> + </div> + </div> <% else %> <input type="submit" class="cbi-button cbi-button-add" name="cbi.cts.<%=self.config%>.<%=self.sectiontype%>.<%=section%>" value="<%:Add%>" /> <% end %> diff --git a/applications/luci-app-firewall/po/ca/firewall.po b/applications/luci-app-firewall/po/ca/firewall.po index ff43427eed..2ccffca9a7 100644 --- a/applications/luci-app-firewall/po/ca/firewall.po +++ b/applications/luci-app-firewall/po/ca/firewall.po @@ -130,6 +130,9 @@ msgstr "Habilita protecció contra la inundació SYN" msgid "Enable logging on this zone" msgstr "Habilita el registre d'aquesta zona" +msgid "Experimental feature. Not fully compatible with QoS/SQM." +msgstr "" + msgid "External IP address" msgstr "Adreça IP extern" @@ -181,6 +184,9 @@ msgstr "Des de %s en %s amb orígens %s i %s" msgid "General Settings" msgstr "Ajusts generals" +msgid "Hardware flow offloading" +msgstr "" + msgid "IP" msgstr "" @@ -337,6 +343,9 @@ msgstr "" msgid "Refuse input" msgstr "" +msgid "Requires hardware NAT support. Implemented at least for mt7621" +msgstr "" + msgid "Restart Firewall" msgstr "" @@ -365,6 +374,9 @@ msgstr "Reescriu a l'origen %s" msgid "Rewrite to source %s, %s" msgstr "Reescriu als orígens %s, %s" +msgid "Routing/NAT Offloading" +msgstr "" + msgid "Rule is disabled" msgstr "" @@ -380,6 +392,12 @@ msgstr "Port SNAT" msgid "Saturday" msgstr "" +msgid "Software based offloading for routing/NAT" +msgstr "" + +msgid "Software flow offloading" +msgstr "" + msgid "Source IP address" msgstr "Adreça IP d'origen" diff --git a/applications/luci-app-firewall/po/cs/firewall.po b/applications/luci-app-firewall/po/cs/firewall.po index caa7e19988..4cbf356d0b 100644 --- a/applications/luci-app-firewall/po/cs/firewall.po +++ b/applications/luci-app-firewall/po/cs/firewall.po @@ -125,6 +125,9 @@ msgstr "Povolit ochranu proti SYN-flood" msgid "Enable logging on this zone" msgstr "Povolit logování v této oblasti" +msgid "Experimental feature. Not fully compatible with QoS/SQM." +msgstr "" + msgid "External IP address" msgstr "Vnější IP adresa" @@ -176,6 +179,9 @@ msgstr "Z %s v %s se zdrojovou %s a %s" msgid "General Settings" msgstr "Obecné nastavení" +msgid "Hardware flow offloading" +msgstr "" + msgid "IP" msgstr "" @@ -334,6 +340,9 @@ msgstr "" msgid "Refuse input" msgstr "" +msgid "Requires hardware NAT support. Implemented at least for mt7621" +msgstr "" + msgid "Restart Firewall" msgstr "" @@ -362,6 +371,9 @@ msgstr "Přepsat na zdrojovou %s" msgid "Rewrite to source %s, %s" msgstr "Přepsat na zdrojovou %s, %s" +msgid "Routing/NAT Offloading" +msgstr "" + msgid "Rule is disabled" msgstr "" @@ -377,6 +389,12 @@ msgstr "Port SNATu" msgid "Saturday" msgstr "" +msgid "Software based offloading for routing/NAT" +msgstr "" + +msgid "Software flow offloading" +msgstr "" + msgid "Source IP address" msgstr "Zdrojová IP adresa" diff --git a/applications/luci-app-firewall/po/de/firewall.po b/applications/luci-app-firewall/po/de/firewall.po index fcf8bec679..0ee6007dd6 100644 --- a/applications/luci-app-firewall/po/de/firewall.po +++ b/applications/luci-app-firewall/po/de/firewall.po @@ -128,6 +128,9 @@ msgstr "Schutz vor SYN-flood-Attacken" msgid "Enable logging on this zone" msgstr "Protokollierung innerhalb der Zone aktivieren" +msgid "Experimental feature. Not fully compatible with QoS/SQM." +msgstr "" + msgid "External IP address" msgstr "Externe IP-Adresse" @@ -179,6 +182,9 @@ msgstr "Von %s in %s mit Quell-%s und %s" msgid "General Settings" msgstr "Allgemein" +msgid "Hardware flow offloading" +msgstr "" + msgid "IP" msgstr "" @@ -334,6 +340,9 @@ msgstr "" msgid "Refuse input" msgstr "" +msgid "Requires hardware NAT support. Implemented at least for mt7621" +msgstr "" + msgid "Restart Firewall" msgstr "" @@ -362,6 +371,9 @@ msgstr "Schreibe um auf Quell-%s" msgid "Rewrite to source %s, %s" msgstr "Schreibe um auf Quell-%s, %s" +msgid "Routing/NAT Offloading" +msgstr "" + msgid "Rule is disabled" msgstr "" @@ -377,6 +389,12 @@ msgstr "SNAT-Port" msgid "Saturday" msgstr "" +msgid "Software based offloading for routing/NAT" +msgstr "" + +msgid "Software flow offloading" +msgstr "" + msgid "Source IP address" msgstr "Quell-IP-Adresse" diff --git a/applications/luci-app-firewall/po/el/firewall.po b/applications/luci-app-firewall/po/el/firewall.po index 598927557b..9ddd4c9db1 100644 --- a/applications/luci-app-firewall/po/el/firewall.po +++ b/applications/luci-app-firewall/po/el/firewall.po @@ -126,6 +126,9 @@ msgstr "Προστασία SYN-flood" msgid "Enable logging on this zone" msgstr "" +msgid "Experimental feature. Not fully compatible with QoS/SQM." +msgstr "" + msgid "External IP address" msgstr "Εξωτερική διεύθυνση IP" @@ -177,6 +180,9 @@ msgstr "" msgid "General Settings" msgstr "Γενικές Ρυθμίσεις" +msgid "Hardware flow offloading" +msgstr "" + msgid "IP" msgstr "" @@ -327,6 +333,9 @@ msgstr "" msgid "Refuse input" msgstr "" +msgid "Requires hardware NAT support. Implemented at least for mt7621" +msgstr "" + msgid "Restart Firewall" msgstr "" @@ -353,6 +362,9 @@ msgstr "" msgid "Rewrite to source %s, %s" msgstr "" +msgid "Routing/NAT Offloading" +msgstr "" + msgid "Rule is disabled" msgstr "" @@ -368,6 +380,12 @@ msgstr "" msgid "Saturday" msgstr "" +msgid "Software based offloading for routing/NAT" +msgstr "" + +msgid "Software flow offloading" +msgstr "" + #, fuzzy msgid "Source IP address" msgstr "Διεύθυνση MAC πηγής" diff --git a/applications/luci-app-firewall/po/en/firewall.po b/applications/luci-app-firewall/po/en/firewall.po index df1ed4a088..f0fe0b3782 100644 --- a/applications/luci-app-firewall/po/en/firewall.po +++ b/applications/luci-app-firewall/po/en/firewall.po @@ -122,6 +122,9 @@ msgstr "Enable SYN-flood protection" msgid "Enable logging on this zone" msgstr "" +msgid "Experimental feature. Not fully compatible with QoS/SQM." +msgstr "" + msgid "External IP address" msgstr "" @@ -177,6 +180,9 @@ msgstr "" msgid "General Settings" msgstr "" +msgid "Hardware flow offloading" +msgstr "" + msgid "IP" msgstr "" @@ -327,6 +333,9 @@ msgstr "" msgid "Refuse input" msgstr "" +msgid "Requires hardware NAT support. Implemented at least for mt7621" +msgstr "" + msgid "Restart Firewall" msgstr "" @@ -353,6 +362,9 @@ msgstr "" msgid "Rewrite to source %s, %s" msgstr "" +msgid "Routing/NAT Offloading" +msgstr "" + msgid "Rule is disabled" msgstr "" @@ -368,6 +380,12 @@ msgstr "" msgid "Saturday" msgstr "" +msgid "Software based offloading for routing/NAT" +msgstr "" + +msgid "Software flow offloading" +msgstr "" + # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # Generated from applications/luci-fw/luasrc/model/cbi/luci_fw/rrule.lua # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # diff --git a/applications/luci-app-firewall/po/es/firewall.po b/applications/luci-app-firewall/po/es/firewall.po index bae8b693da..000853e9bd 100644 --- a/applications/luci-app-firewall/po/es/firewall.po +++ b/applications/luci-app-firewall/po/es/firewall.po @@ -129,6 +129,9 @@ msgstr "Activar protección a inundación-SYN" msgid "Enable logging on this zone" msgstr "Activar registro en esta zona" +msgid "Experimental feature. Not fully compatible with QoS/SQM." +msgstr "" + msgid "External IP address" msgstr "Dirección IP externa" @@ -180,6 +183,9 @@ msgstr "Desde %s en %s con origen %s y %s" msgid "General Settings" msgstr "Configuración general" +msgid "Hardware flow offloading" +msgstr "" + msgid "IP" msgstr "" @@ -336,6 +342,9 @@ msgstr "" msgid "Refuse input" msgstr "" +msgid "Requires hardware NAT support. Implemented at least for mt7621" +msgstr "" + msgid "Restart Firewall" msgstr "" @@ -364,6 +373,9 @@ msgstr "Reescribir a origen %s" msgid "Rewrite to source %s, %s" msgstr "Reescribir a origen %s, %s" +msgid "Routing/NAT Offloading" +msgstr "" + msgid "Rule is disabled" msgstr "" @@ -379,6 +391,12 @@ msgstr "Puerto SNAT" msgid "Saturday" msgstr "" +msgid "Software based offloading for routing/NAT" +msgstr "" + +msgid "Software flow offloading" +msgstr "" + msgid "Source IP address" msgstr "Dirección IP origen" diff --git a/applications/luci-app-firewall/po/fr/firewall.po b/applications/luci-app-firewall/po/fr/firewall.po index 281999b550..74c28b8836 100644 --- a/applications/luci-app-firewall/po/fr/firewall.po +++ b/applications/luci-app-firewall/po/fr/firewall.po @@ -124,6 +124,9 @@ msgstr "Activer la protection contre le SYN-flood" msgid "Enable logging on this zone" msgstr "Activer les traces (logs) sur cette zone" +msgid "Experimental feature. Not fully compatible with QoS/SQM." +msgstr "" + msgid "External IP address" msgstr "Adresse IP externe" @@ -179,6 +182,9 @@ msgstr "" msgid "General Settings" msgstr "Paramètres généraux" +msgid "Hardware flow offloading" +msgstr "" + msgid "IP" msgstr "" @@ -332,6 +338,9 @@ msgstr "" msgid "Refuse input" msgstr "" +msgid "Requires hardware NAT support. Implemented at least for mt7621" +msgstr "" + msgid "Restart Firewall" msgstr "" @@ -362,6 +371,9 @@ msgstr "" msgid "Rewrite to source %s, %s" msgstr "" +msgid "Routing/NAT Offloading" +msgstr "" + msgid "Rule is disabled" msgstr "" @@ -377,6 +389,12 @@ msgstr "Port SNAT" msgid "Saturday" msgstr "" +msgid "Software based offloading for routing/NAT" +msgstr "" + +msgid "Software flow offloading" +msgstr "" + # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # applications/luci-fw/luasrc/model/cbi/luci_fw/rrule.lua # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # diff --git a/applications/luci-app-firewall/po/he/firewall.po b/applications/luci-app-firewall/po/he/firewall.po index 06952d4901..0416661c26 100644 --- a/applications/luci-app-firewall/po/he/firewall.po +++ b/applications/luci-app-firewall/po/he/firewall.po @@ -119,6 +119,9 @@ msgstr "" msgid "Enable logging on this zone" msgstr "" +msgid "Experimental feature. Not fully compatible with QoS/SQM." +msgstr "" + msgid "External IP address" msgstr "" @@ -170,6 +173,9 @@ msgstr "" msgid "General Settings" msgstr "" +msgid "Hardware flow offloading" +msgstr "" + msgid "IP" msgstr "" @@ -317,6 +323,9 @@ msgstr "" msgid "Refuse input" msgstr "" +msgid "Requires hardware NAT support. Implemented at least for mt7621" +msgstr "" + msgid "Restart Firewall" msgstr "" @@ -343,6 +352,9 @@ msgstr "" msgid "Rewrite to source %s, %s" msgstr "" +msgid "Routing/NAT Offloading" +msgstr "" + msgid "Rule is disabled" msgstr "" @@ -358,6 +370,12 @@ msgstr "" msgid "Saturday" msgstr "" +msgid "Software based offloading for routing/NAT" +msgstr "" + +msgid "Software flow offloading" +msgstr "" + msgid "Source IP address" msgstr "" diff --git a/applications/luci-app-firewall/po/hu/firewall.po b/applications/luci-app-firewall/po/hu/firewall.po index 29aa324187..33a305ce8e 100644 --- a/applications/luci-app-firewall/po/hu/firewall.po +++ b/applications/luci-app-firewall/po/hu/firewall.po @@ -126,6 +126,9 @@ msgstr "SYN-flood védelem engedélyezése" msgid "Enable logging on this zone" msgstr "Naplózás engeélyezése ezen a zónán" +msgid "Experimental feature. Not fully compatible with QoS/SQM." +msgstr "" + msgid "External IP address" msgstr "Külső IP cím" @@ -177,6 +180,9 @@ msgstr "%s felől %s-ben %s és %s forrással" msgid "General Settings" msgstr "Általános beállítások" +msgid "Hardware flow offloading" +msgstr "" + msgid "IP" msgstr "" @@ -338,6 +344,9 @@ msgstr "" msgid "Refuse input" msgstr "" +msgid "Requires hardware NAT support. Implemented at least for mt7621" +msgstr "" + msgid "Restart Firewall" msgstr "" @@ -366,6 +375,9 @@ msgstr "Átírás %s forrásra" msgid "Rewrite to source %s, %s" msgstr "Átírás %s, %s forrásra" +msgid "Routing/NAT Offloading" +msgstr "" + msgid "Rule is disabled" msgstr "" @@ -381,6 +393,12 @@ msgstr "SNAT port" msgid "Saturday" msgstr "" +msgid "Software based offloading for routing/NAT" +msgstr "" + +msgid "Software flow offloading" +msgstr "" + msgid "Source IP address" msgstr "Forrás IP cím" diff --git a/applications/luci-app-firewall/po/it/firewall.po b/applications/luci-app-firewall/po/it/firewall.po index 43b90a9e9b..4808d12475 100644 --- a/applications/luci-app-firewall/po/it/firewall.po +++ b/applications/luci-app-firewall/po/it/firewall.po @@ -128,6 +128,9 @@ msgstr "Attiva protezione SYN-flood" msgid "Enable logging on this zone" msgstr "Attiva registro su questa zona" +msgid "Experimental feature. Not fully compatible with QoS/SQM." +msgstr "" + msgid "External IP address" msgstr "Indirizzo IP Esterno" @@ -179,6 +182,9 @@ msgstr "Da %s a %s con sorgente %s e %s" msgid "General Settings" msgstr "Opzioni Generali" +msgid "Hardware flow offloading" +msgstr "" + msgid "IP" msgstr "" @@ -334,6 +340,9 @@ msgstr "" msgid "Refuse input" msgstr "" +msgid "Requires hardware NAT support. Implemented at least for mt7621" +msgstr "" + msgid "Restart Firewall" msgstr "Riavvia Firewall" @@ -362,6 +371,9 @@ msgstr "Riscrivi alla sorgente %s" msgid "Rewrite to source %s, %s" msgstr "Riscrivi alla sorgente %s, %s" +msgid "Routing/NAT Offloading" +msgstr "" + msgid "Rule is disabled" msgstr "" @@ -377,6 +389,12 @@ msgstr "Porta SNAT" msgid "Saturday" msgstr "Sabato" +msgid "Software based offloading for routing/NAT" +msgstr "" + +msgid "Software flow offloading" +msgstr "" + # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # Generated from applications/luci-fw/luasrc/model/cbi/luci_fw/rrule.lua # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # diff --git a/applications/luci-app-firewall/po/ja/firewall.po b/applications/luci-app-firewall/po/ja/firewall.po index 2d252797ff..27109904ba 100644 --- a/applications/luci-app-firewall/po/ja/firewall.po +++ b/applications/luci-app-firewall/po/ja/firewall.po @@ -3,14 +3,14 @@ msgstr "" "Project-Id-Version: \n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2010-03-30 17:00+0200\n" -"PO-Revision-Date: 2018-01-15 14:56+0900\n" +"PO-Revision-Date: 2018-05-27 21:24+0900\n" "Last-Translator: INAGAKI Hiroshi <musashino.open@gmail.com>\n" "Language: ja\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=1; plural=0;\n" -"X-Generator: Poedit 2.0.5\n" +"X-Generator: Poedit 2.0.7\n" "Language-Team: \n" msgid "%s in %s" @@ -129,6 +129,9 @@ msgstr "SYN-Floodプロテクションを有効にする" msgid "Enable logging on this zone" msgstr "このゾーンのログ記録を有効にする" +msgid "Experimental feature. Not fully compatible with QoS/SQM." +msgstr "実験的な機能です。 QoS/SQM との完全な互換性はありません。" + msgid "External IP address" msgstr "外部IPアドレス" @@ -180,6 +183,9 @@ msgstr "送信元 %s (%s) , 送信元 %s, 送信元 %s" msgid "General Settings" msgstr "一般設定" +msgid "Hardware flow offloading" +msgstr "ハードウェア フローオフロード" + msgid "IP" msgstr "IP" @@ -343,6 +349,10 @@ msgstr "転送を拒否" msgid "Refuse input" msgstr "入力を拒否" +msgid "Requires hardware NAT support. Implemented at least for mt7621" +msgstr "" +"ハードウェア NAT サポートが必要です。 mt7621 のみにおいて実装されています。" + msgid "Restart Firewall" msgstr "ファイアウォールの再起動" @@ -372,6 +382,9 @@ msgstr "送信元 %s にリライト" msgid "Rewrite to source %s, %s" msgstr "送信元 %s, %s にリライト" +msgid "Routing/NAT Offloading" +msgstr "ルーティング/NAT オフロード" + msgid "Rule is disabled" msgstr "ルールは無効です" @@ -387,6 +400,12 @@ msgstr "SNAT ポート" msgid "Saturday" msgstr "土曜日" +msgid "Software based offloading for routing/NAT" +msgstr "ルーティング/NAT のための、ソフトウェアベースのオフロードです。" + +msgid "Software flow offloading" +msgstr "ソフトウェア フローオフロード" + # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # Generated from applications/luci-fw/luasrc/model/cbi/luci_fw/rrule.lua # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # diff --git a/applications/luci-app-firewall/po/ko/firewall.po b/applications/luci-app-firewall/po/ko/firewall.po index bfe94d04a8..dd4f96197a 100644 --- a/applications/luci-app-firewall/po/ko/firewall.po +++ b/applications/luci-app-firewall/po/ko/firewall.po @@ -127,6 +127,9 @@ msgstr "SYN-flood protection 활성화" msgid "Enable logging on this zone" msgstr "zone 의 logging 활성화" +msgid "Experimental feature. Not fully compatible with QoS/SQM." +msgstr "" + msgid "External IP address" msgstr "외부 IP 주소" @@ -178,6 +181,9 @@ msgstr "" msgid "General Settings" msgstr "" +msgid "Hardware flow offloading" +msgstr "" + msgid "IP" msgstr "" @@ -327,6 +333,9 @@ msgstr "" msgid "Refuse input" msgstr "" +msgid "Requires hardware NAT support. Implemented at least for mt7621" +msgstr "" + msgid "Restart Firewall" msgstr "" @@ -353,6 +362,9 @@ msgstr "" msgid "Rewrite to source %s, %s" msgstr "" +msgid "Routing/NAT Offloading" +msgstr "" + msgid "Rule is disabled" msgstr "" @@ -368,6 +380,12 @@ msgstr "" msgid "Saturday" msgstr "토요일" +msgid "Software based offloading for routing/NAT" +msgstr "" + +msgid "Software flow offloading" +msgstr "" + msgid "Source IP address" msgstr "Source IP 주소" diff --git a/applications/luci-app-firewall/po/ms/firewall.po b/applications/luci-app-firewall/po/ms/firewall.po index c6ab19791e..58aea1fd0b 100644 --- a/applications/luci-app-firewall/po/ms/firewall.po +++ b/applications/luci-app-firewall/po/ms/firewall.po @@ -118,6 +118,9 @@ msgstr "" msgid "Enable logging on this zone" msgstr "" +msgid "Experimental feature. Not fully compatible with QoS/SQM." +msgstr "" + msgid "External IP address" msgstr "" @@ -169,6 +172,9 @@ msgstr "" msgid "General Settings" msgstr "" +msgid "Hardware flow offloading" +msgstr "" + msgid "IP" msgstr "" @@ -316,6 +322,9 @@ msgstr "" msgid "Refuse input" msgstr "" +msgid "Requires hardware NAT support. Implemented at least for mt7621" +msgstr "" + msgid "Restart Firewall" msgstr "" @@ -342,6 +351,9 @@ msgstr "" msgid "Rewrite to source %s, %s" msgstr "" +msgid "Routing/NAT Offloading" +msgstr "" + msgid "Rule is disabled" msgstr "" @@ -357,6 +369,12 @@ msgstr "" msgid "Saturday" msgstr "" +msgid "Software based offloading for routing/NAT" +msgstr "" + +msgid "Software flow offloading" +msgstr "" + msgid "Source IP address" msgstr "" diff --git a/applications/luci-app-firewall/po/no/firewall.po b/applications/luci-app-firewall/po/no/firewall.po index e9ecb2b63c..2a13b6b3cd 100644 --- a/applications/luci-app-firewall/po/no/firewall.po +++ b/applications/luci-app-firewall/po/no/firewall.po @@ -122,6 +122,9 @@ msgstr "Aktiver SYN-flood beskyttelse" msgid "Enable logging on this zone" msgstr "Aktiver logging av denne sonen" +msgid "Experimental feature. Not fully compatible with QoS/SQM." +msgstr "" + msgid "External IP address" msgstr "Ekstern IP adressse" @@ -174,6 +177,9 @@ msgstr "Fra %s i %s med kilde %s og %s" msgid "General Settings" msgstr "Generelle Innstillinger" +msgid "Hardware flow offloading" +msgstr "" + msgid "IP" msgstr "" @@ -333,6 +339,9 @@ msgstr "" msgid "Refuse input" msgstr "" +msgid "Requires hardware NAT support. Implemented at least for mt7621" +msgstr "" + msgid "Restart Firewall" msgstr "" @@ -361,6 +370,9 @@ msgstr "Omskriv til kilde %s" msgid "Rewrite to source %s, %s" msgstr "Omskriv til kilde %s, %s" +msgid "Routing/NAT Offloading" +msgstr "" + msgid "Rule is disabled" msgstr "" @@ -376,6 +388,12 @@ msgstr "SNAT port" msgid "Saturday" msgstr "" +msgid "Software based offloading for routing/NAT" +msgstr "" + +msgid "Software flow offloading" +msgstr "" + msgid "Source IP address" msgstr "Kilde IP adresse" diff --git a/applications/luci-app-firewall/po/pl/firewall.po b/applications/luci-app-firewall/po/pl/firewall.po index fe48060237..a08a1e5606 100644 --- a/applications/luci-app-firewall/po/pl/firewall.po +++ b/applications/luci-app-firewall/po/pl/firewall.po @@ -129,6 +129,9 @@ msgstr "Włącz ochronę przed atakiem SYN-flood" msgid "Enable logging on this zone" msgstr "Włącz logowanie na tej strefy" +msgid "Experimental feature. Not fully compatible with QoS/SQM." +msgstr "" + msgid "External IP address" msgstr "Zewnętrzne adresy IP" @@ -183,6 +186,9 @@ msgstr "Z %s w %s ze źródłem %s i %s" msgid "General Settings" msgstr "Ustawienia ogólne" +msgid "Hardware flow offloading" +msgstr "" + msgid "IP" msgstr "" @@ -342,6 +348,9 @@ msgstr "" msgid "Refuse input" msgstr "" +msgid "Requires hardware NAT support. Implemented at least for mt7621" +msgstr "" + msgid "Restart Firewall" msgstr "" @@ -374,6 +383,9 @@ msgstr "Przepisz do źródła %s" msgid "Rewrite to source %s, %s" msgstr "Przepisz do źródła %s, %s" +msgid "Routing/NAT Offloading" +msgstr "" + msgid "Rule is disabled" msgstr "" @@ -389,6 +401,12 @@ msgstr "Port SNAT" msgid "Saturday" msgstr "" +msgid "Software based offloading for routing/NAT" +msgstr "" + +msgid "Software flow offloading" +msgstr "" + msgid "Source IP address" msgstr "Źródłowy adres IP" diff --git a/applications/luci-app-firewall/po/pt-br/firewall.po b/applications/luci-app-firewall/po/pt-br/firewall.po index b49adccdda..7da028bee4 100644 --- a/applications/luci-app-firewall/po/pt-br/firewall.po +++ b/applications/luci-app-firewall/po/pt-br/firewall.po @@ -127,6 +127,9 @@ msgstr "Habilite proteção contra SYN-flood" msgid "Enable logging on this zone" msgstr "Habilite o registro nesta zona" +msgid "Experimental feature. Not fully compatible with QoS/SQM." +msgstr "" + msgid "External IP address" msgstr "Endereço IP externo" @@ -178,6 +181,9 @@ msgstr "Vindo de %s em %s com origem %s e %s" msgid "General Settings" msgstr "Configurações Gerais" +msgid "Hardware flow offloading" +msgstr "" + msgid "IP" msgstr "" @@ -337,6 +343,9 @@ msgstr "" msgid "Refuse input" msgstr "" +msgid "Requires hardware NAT support. Implemented at least for mt7621" +msgstr "" + msgid "Restart Firewall" msgstr "Reiniciar o Firewall" @@ -365,6 +374,9 @@ msgstr "Reescrever para a origem %s" msgid "Rewrite to source %s, %s" msgstr "Reescrever para a origem %s, %s" +msgid "Routing/NAT Offloading" +msgstr "" + msgid "Rule is disabled" msgstr "" @@ -380,6 +392,12 @@ msgstr "Porta da SNAT" msgid "Saturday" msgstr "Sábado" +msgid "Software based offloading for routing/NAT" +msgstr "" + +msgid "Software flow offloading" +msgstr "" + msgid "Source IP address" msgstr "Endereço IP de origem" diff --git a/applications/luci-app-firewall/po/pt/firewall.po b/applications/luci-app-firewall/po/pt/firewall.po index 29a7c7c2c7..543489e1ad 100644 --- a/applications/luci-app-firewall/po/pt/firewall.po +++ b/applications/luci-app-firewall/po/pt/firewall.po @@ -128,6 +128,9 @@ msgstr "Ativar a Proteção SYN-flood" msgid "Enable logging on this zone" msgstr "Ativar registo nesta zona" +msgid "Experimental feature. Not fully compatible with QoS/SQM." +msgstr "" + msgid "External IP address" msgstr "Endereço IP externo" @@ -179,6 +182,9 @@ msgstr "De %s em %s com origem %s e %s" msgid "General Settings" msgstr "Definições Gerais" +msgid "Hardware flow offloading" +msgstr "" + msgid "IP" msgstr "" @@ -339,6 +345,9 @@ msgstr "" msgid "Refuse input" msgstr "" +msgid "Requires hardware NAT support. Implemented at least for mt7621" +msgstr "" + msgid "Restart Firewall" msgstr "" @@ -365,6 +374,9 @@ msgstr "Re-escrever para a origem %s" msgid "Rewrite to source %s, %s" msgstr "Re-escrever para a origem %s, %s" +msgid "Routing/NAT Offloading" +msgstr "" + msgid "Rule is disabled" msgstr "" @@ -380,6 +392,12 @@ msgstr "Porta SNAT" msgid "Saturday" msgstr "" +msgid "Software based offloading for routing/NAT" +msgstr "" + +msgid "Software flow offloading" +msgstr "" + msgid "Source IP address" msgstr "Endereço IP de origem" diff --git a/applications/luci-app-firewall/po/ro/firewall.po b/applications/luci-app-firewall/po/ro/firewall.po index cc4d7a62af..937efe722b 100644 --- a/applications/luci-app-firewall/po/ro/firewall.po +++ b/applications/luci-app-firewall/po/ro/firewall.po @@ -123,6 +123,9 @@ msgstr "Activează protecţia SYN-flood" msgid "Enable logging on this zone" msgstr "Activeaza log in aceasta zona" +msgid "Experimental feature. Not fully compatible with QoS/SQM." +msgstr "" + msgid "External IP address" msgstr "Adresă IP externă" @@ -174,6 +177,9 @@ msgstr "" msgid "General Settings" msgstr "Setari generale" +msgid "Hardware flow offloading" +msgstr "" + msgid "IP" msgstr "" @@ -321,6 +327,9 @@ msgstr "" msgid "Refuse input" msgstr "" +msgid "Requires hardware NAT support. Implemented at least for mt7621" +msgstr "" + msgid "Restart Firewall" msgstr "" @@ -347,6 +356,9 @@ msgstr "" msgid "Rewrite to source %s, %s" msgstr "" +msgid "Routing/NAT Offloading" +msgstr "" + msgid "Rule is disabled" msgstr "" @@ -362,6 +374,12 @@ msgstr "" msgid "Saturday" msgstr "" +msgid "Software based offloading for routing/NAT" +msgstr "" + +msgid "Software flow offloading" +msgstr "" + msgid "Source IP address" msgstr "Sursă adresă IP" diff --git a/applications/luci-app-firewall/po/ru/firewall.po b/applications/luci-app-firewall/po/ru/firewall.po index b8611af780..528756d7e3 100644 --- a/applications/luci-app-firewall/po/ru/firewall.po +++ b/applications/luci-app-firewall/po/ru/firewall.po @@ -130,6 +130,9 @@ msgstr "Включить защиту<br />от SYN-flood атак" msgid "Enable logging on this zone" msgstr "Включить журналирование в этой зоне" +msgid "Experimental feature. Not fully compatible with QoS/SQM." +msgstr "" + msgid "External IP address" msgstr "Внешний IP-адрес" @@ -181,6 +184,9 @@ msgstr "Из %s в %s с источниками %s и %s" msgid "General Settings" msgstr "Основные настройки" +msgid "Hardware flow offloading" +msgstr "" + msgid "IP" msgstr "IP-адрес" @@ -346,6 +352,9 @@ msgstr "Сбрасывать перенаправление" msgid "Refuse input" msgstr "Сбрасывать входящий трафик" +msgid "Requires hardware NAT support. Implemented at least for mt7621" +msgstr "" + msgid "Restart Firewall" msgstr "Перезапустить межсетевой экран" @@ -374,6 +383,9 @@ msgstr "Перенаправлять к источнику %s" msgid "Rewrite to source %s, %s" msgstr "Перенаправлять к источнику %s, %s" +msgid "Routing/NAT Offloading" +msgstr "" + msgid "Rule is disabled" msgstr "Правило отключено" @@ -389,6 +401,12 @@ msgstr "Порт SNAT" msgid "Saturday" msgstr "Суббота" +msgid "Software based offloading for routing/NAT" +msgstr "" + +msgid "Software flow offloading" +msgstr "" + msgid "Source IP address" msgstr "IP-адрес источника" diff --git a/applications/luci-app-firewall/po/sk/firewall.po b/applications/luci-app-firewall/po/sk/firewall.po index a185625a02..a382bde7db 100644 --- a/applications/luci-app-firewall/po/sk/firewall.po +++ b/applications/luci-app-firewall/po/sk/firewall.po @@ -119,6 +119,9 @@ msgstr "" msgid "Enable logging on this zone" msgstr "" +msgid "Experimental feature. Not fully compatible with QoS/SQM." +msgstr "" + msgid "External IP address" msgstr "" @@ -170,6 +173,9 @@ msgstr "" msgid "General Settings" msgstr "" +msgid "Hardware flow offloading" +msgstr "" + msgid "IP" msgstr "" @@ -317,6 +323,9 @@ msgstr "" msgid "Refuse input" msgstr "" +msgid "Requires hardware NAT support. Implemented at least for mt7621" +msgstr "" + msgid "Restart Firewall" msgstr "" @@ -343,6 +352,9 @@ msgstr "" msgid "Rewrite to source %s, %s" msgstr "" +msgid "Routing/NAT Offloading" +msgstr "" + msgid "Rule is disabled" msgstr "" @@ -358,6 +370,12 @@ msgstr "" msgid "Saturday" msgstr "" +msgid "Software based offloading for routing/NAT" +msgstr "" + +msgid "Software flow offloading" +msgstr "" + msgid "Source IP address" msgstr "" diff --git a/applications/luci-app-firewall/po/sv/firewall.po b/applications/luci-app-firewall/po/sv/firewall.po index c98eafa09a..d5f6a2d8a5 100644 --- a/applications/luci-app-firewall/po/sv/firewall.po +++ b/applications/luci-app-firewall/po/sv/firewall.po @@ -120,6 +120,9 @@ msgstr "" msgid "Enable logging on this zone" msgstr "Aktivera loggning i den här zonen" +msgid "Experimental feature. Not fully compatible with QoS/SQM." +msgstr "" + msgid "External IP address" msgstr "Extern IP-adress" @@ -171,6 +174,9 @@ msgstr "Från %s i %s med källa %s och %s" msgid "General Settings" msgstr "Generella inställningar" +msgid "Hardware flow offloading" +msgstr "" + msgid "IP" msgstr "" @@ -323,6 +329,9 @@ msgstr "" msgid "Refuse input" msgstr "" +msgid "Requires hardware NAT support. Implemented at least for mt7621" +msgstr "" + msgid "Restart Firewall" msgstr "Starta om brandvägg" @@ -349,6 +358,9 @@ msgstr "Skriv om igen till källan %s" msgid "Rewrite to source %s, %s" msgstr "" +msgid "Routing/NAT Offloading" +msgstr "" + msgid "Rule is disabled" msgstr "" @@ -364,6 +376,12 @@ msgstr "SNAT-port" msgid "Saturday" msgstr "Lördag" +msgid "Software based offloading for routing/NAT" +msgstr "" + +msgid "Software flow offloading" +msgstr "" + msgid "Source IP address" msgstr "IP-adress för källa" diff --git a/applications/luci-app-firewall/po/templates/firewall.pot b/applications/luci-app-firewall/po/templates/firewall.pot index 62c4a2e84a..6ff4c3ca0f 100644 --- a/applications/luci-app-firewall/po/templates/firewall.pot +++ b/applications/luci-app-firewall/po/templates/firewall.pot @@ -112,6 +112,9 @@ msgstr "" msgid "Enable logging on this zone" msgstr "" +msgid "Experimental feature. Not fully compatible with QoS/SQM." +msgstr "" + msgid "External IP address" msgstr "" @@ -163,6 +166,9 @@ msgstr "" msgid "General Settings" msgstr "" +msgid "Hardware flow offloading" +msgstr "" + msgid "IP" msgstr "" @@ -310,6 +316,9 @@ msgstr "" msgid "Refuse input" msgstr "" +msgid "Requires hardware NAT support. Implemented at least for mt7621" +msgstr "" + msgid "Restart Firewall" msgstr "" @@ -336,6 +345,9 @@ msgstr "" msgid "Rewrite to source %s, %s" msgstr "" +msgid "Routing/NAT Offloading" +msgstr "" + msgid "Rule is disabled" msgstr "" @@ -351,6 +363,12 @@ msgstr "" msgid "Saturday" msgstr "" +msgid "Software based offloading for routing/NAT" +msgstr "" + +msgid "Software flow offloading" +msgstr "" + msgid "Source IP address" msgstr "" diff --git a/applications/luci-app-firewall/po/tr/firewall.po b/applications/luci-app-firewall/po/tr/firewall.po index f23d10aafc..1dd1e6f9cf 100644 --- a/applications/luci-app-firewall/po/tr/firewall.po +++ b/applications/luci-app-firewall/po/tr/firewall.po @@ -119,6 +119,9 @@ msgstr "" msgid "Enable logging on this zone" msgstr "" +msgid "Experimental feature. Not fully compatible with QoS/SQM." +msgstr "" + msgid "External IP address" msgstr "" @@ -170,6 +173,9 @@ msgstr "" msgid "General Settings" msgstr "" +msgid "Hardware flow offloading" +msgstr "" + msgid "IP" msgstr "" @@ -317,6 +323,9 @@ msgstr "" msgid "Refuse input" msgstr "" +msgid "Requires hardware NAT support. Implemented at least for mt7621" +msgstr "" + msgid "Restart Firewall" msgstr "" @@ -343,6 +352,9 @@ msgstr "" msgid "Rewrite to source %s, %s" msgstr "" +msgid "Routing/NAT Offloading" +msgstr "" + msgid "Rule is disabled" msgstr "" @@ -358,6 +370,12 @@ msgstr "" msgid "Saturday" msgstr "" +msgid "Software based offloading for routing/NAT" +msgstr "" + +msgid "Software flow offloading" +msgstr "" + msgid "Source IP address" msgstr "" diff --git a/applications/luci-app-firewall/po/uk/firewall.po b/applications/luci-app-firewall/po/uk/firewall.po index de72ec6e0a..86ff65edf1 100644 --- a/applications/luci-app-firewall/po/uk/firewall.po +++ b/applications/luci-app-firewall/po/uk/firewall.po @@ -127,6 +127,9 @@ msgstr "Увімкнути захист від SYN-flood" msgid "Enable logging on this zone" msgstr "Увімкнути реєстрування у цій зоні" +msgid "Experimental feature. Not fully compatible with QoS/SQM." +msgstr "" + msgid "External IP address" msgstr "Зовнішня IP-адреса" @@ -178,6 +181,9 @@ msgstr "%s у %s з вихідним %s та %s" msgid "General Settings" msgstr "Загальні настройки" +msgid "Hardware flow offloading" +msgstr "" + msgid "IP" msgstr "" @@ -337,6 +343,9 @@ msgstr "" msgid "Refuse input" msgstr "" +msgid "Requires hardware NAT support. Implemented at least for mt7621" +msgstr "" + msgid "Restart Firewall" msgstr "" @@ -365,6 +374,9 @@ msgstr "перезапис на вихідний %s" msgid "Rewrite to source %s, %s" msgstr "перезапис на вихідний %s, %s" +msgid "Routing/NAT Offloading" +msgstr "" + msgid "Rule is disabled" msgstr "" @@ -380,6 +392,12 @@ msgstr "Порт SNAT" msgid "Saturday" msgstr "" +msgid "Software based offloading for routing/NAT" +msgstr "" + +msgid "Software flow offloading" +msgstr "" + msgid "Source IP address" msgstr "IP-адреса джерела" diff --git a/applications/luci-app-firewall/po/vi/firewall.po b/applications/luci-app-firewall/po/vi/firewall.po index 24452ff1c0..bd33afcd09 100644 --- a/applications/luci-app-firewall/po/vi/firewall.po +++ b/applications/luci-app-firewall/po/vi/firewall.po @@ -126,6 +126,9 @@ msgstr "SYN-flood bảo vệ " msgid "Enable logging on this zone" msgstr "" +msgid "Experimental feature. Not fully compatible with QoS/SQM." +msgstr "" + msgid "External IP address" msgstr "" @@ -177,6 +180,9 @@ msgstr "" msgid "General Settings" msgstr "" +msgid "Hardware flow offloading" +msgstr "" + msgid "IP" msgstr "" @@ -327,6 +333,9 @@ msgstr "" msgid "Refuse input" msgstr "" +msgid "Requires hardware NAT support. Implemented at least for mt7621" +msgstr "" + msgid "Restart Firewall" msgstr "" @@ -353,6 +362,9 @@ msgstr "" msgid "Rewrite to source %s, %s" msgstr "" +msgid "Routing/NAT Offloading" +msgstr "" + msgid "Rule is disabled" msgstr "" @@ -368,6 +380,12 @@ msgstr "" msgid "Saturday" msgstr "" +msgid "Software based offloading for routing/NAT" +msgstr "" + +msgid "Software flow offloading" +msgstr "" + #, fuzzy msgid "Source IP address" msgstr "Đỉa chỉ MAC nguồn" diff --git a/applications/luci-app-firewall/po/zh-cn/firewall.po b/applications/luci-app-firewall/po/zh-cn/firewall.po index 9e9c64d670..46da547c08 100644 --- a/applications/luci-app-firewall/po/zh-cn/firewall.po +++ b/applications/luci-app-firewall/po/zh-cn/firewall.po @@ -124,6 +124,9 @@ msgstr "启用 SYN-flood 防御" msgid "Enable logging on this zone" msgstr "启用此区域的日志记录" +msgid "Experimental feature. Not fully compatible with QoS/SQM." +msgstr "实验特性。与 QoS/SQM 不完全兼容。" + msgid "External IP address" msgstr "外部 IP 地址" @@ -175,6 +178,9 @@ msgstr "来自 %s 位于 %s 源端口 %s 源 MAC %s" msgid "General Settings" msgstr "基本设置" +msgid "Hardware flow offloading" +msgstr "硬件流量卸载" + msgid "IP" msgstr "IP" @@ -323,6 +329,9 @@ msgstr "拒绝转发" msgid "Refuse input" msgstr "拒绝入站" +msgid "Requires hardware NAT support. Implemented at least for mt7621" +msgstr "需要硬件 NAT 支持。目前 mt7621 已实现" + msgid "Restart Firewall" msgstr "重启防火墙" @@ -349,6 +358,9 @@ msgstr "源地址改写成 %s" msgid "Rewrite to source %s, %s" msgstr "源地址改写成 %s, %s" +msgid "Routing/NAT Offloading" +msgstr "Routing/NAT 卸载" + msgid "Rule is disabled" msgstr "规则已禁用" @@ -364,6 +376,12 @@ msgstr "SNAT 端口" msgid "Saturday" msgstr "星期六" +msgid "Software based offloading for routing/NAT" +msgstr "基于软件的 Routing/NAT 卸载" + +msgid "Software flow offloading" +msgstr "软件流量卸载" + msgid "Source IP address" msgstr "源 IP 地址" diff --git a/applications/luci-app-firewall/po/zh-tw/firewall.po b/applications/luci-app-firewall/po/zh-tw/firewall.po index afc9c4e33c..1fbe970ddb 100644 --- a/applications/luci-app-firewall/po/zh-tw/firewall.po +++ b/applications/luci-app-firewall/po/zh-tw/firewall.po @@ -124,6 +124,9 @@ msgstr "啟用 SYN-flood 防禦" msgid "Enable logging on this zone" msgstr "啟用此區域的日誌記錄" +msgid "Experimental feature. Not fully compatible with QoS/SQM." +msgstr "" + msgid "External IP address" msgstr "外部 IP 位址" @@ -175,6 +178,9 @@ msgstr "來自 %s 位於 %s 源埠 %s 源 MAC %s" msgid "General Settings" msgstr "基本設定" +msgid "Hardware flow offloading" +msgstr "" + msgid "IP" msgstr "" @@ -322,6 +328,9 @@ msgstr "" msgid "Refuse input" msgstr "" +msgid "Requires hardware NAT support. Implemented at least for mt7621" +msgstr "" + msgid "Restart Firewall" msgstr "重啟防火牆" @@ -348,6 +357,9 @@ msgstr "源位址改寫成 %s" msgid "Rewrite to source %s, %s" msgstr "源位址改寫成 %s, %s" +msgid "Routing/NAT Offloading" +msgstr "" + msgid "Rule is disabled" msgstr "" @@ -363,6 +375,12 @@ msgstr "SNAT 埠" msgid "Saturday" msgstr "星期六" +msgid "Software based offloading for routing/NAT" +msgstr "" + +msgid "Software flow offloading" +msgstr "" + msgid "Source IP address" msgstr "源 IP 位址" diff --git a/applications/luci-app-ltqtapi/luasrc/view/telephony_status.htm b/applications/luci-app-ltqtapi/luasrc/view/telephony_status.htm index d861ef9fcb..2fd7168bd2 100644 --- a/applications/luci-app-ltqtapi/luasrc/view/telephony_status.htm +++ b/applications/luci-app-ltqtapi/luasrc/view/telephony_status.htm @@ -5,13 +5,12 @@ XHR.poll(5, '<%=url('admin/telephony/status')%>', null, var tb = document.getElementById('telephony_status_table'); if (st && tb) { - tb.deleteRow(1); - var tr = tb.insertRow(-1); - tr.className = 'cbi-section-table-row cbi-rowstyle-1'; - - tr.insertCell(-1).innerHTML = st.status; - tr.insertCell(-1).innerHTML = st.line1; - tr.insertCell(-1).innerHTML = st.line2; + tb.removeChild(tb.firstChild); + tb.appendChild(E('<div class="tr cbi-section-table-row cbi-rowstyle-1">', [ + E('<div class="td">', st.status), + E('<div class="td">', st.line1), + E('<div class="td">', st.line2) + ])); } } ); @@ -19,14 +18,14 @@ XHR.poll(5, '<%=url('admin/telephony/status')%>', null, <fieldset class="cbi-section"> <legend><%:Current Telephony State%></legend> - <table class="cbi-section-table" id="telephony_status_table"> - <tr class="cbi-section-table-titles"> - <th class="cbi-section-table-cell"><%:Uplink%></th> - <th class="cbi-section-table-cell"><%:Port1%></th> - <th class="cbi-section-table-cell"><%:Port2%></th> - </tr> - <tr class="cbi-section-table-row"> - <td colspan="5"><em><br /><%:Collecting data...%></em></td> - </tr> - </table> + <div class="table cbi-section-table" id="telephony_status_table"> + <div class="tr cbi-section-table-titles"> + <div class="th cbi-section-table-cell"><%:Uplink%></div> + <div class="th cbi-section-table-cell"><%:Port1%></div> + <div class="th cbi-section-table-cell"><%:Port2%></div> + </div> + <div class="tr cbi-section-table-row"> + <div class="td" colspan="5"><em><br /><%:Collecting data...%></em></div> + </div> + </div> </fieldset> diff --git a/applications/luci-app-lxc/Makefile b/applications/luci-app-lxc/Makefile index 85cae5c405..379cccbfc9 100644 --- a/applications/luci-app-lxc/Makefile +++ b/applications/luci-app-lxc/Makefile @@ -7,7 +7,7 @@ include $(TOPDIR)/rules.mk LUCI_TITLE:=LXC management Web UI -LUCI_DEPENDS:=+luci-mod-admin-full +lxc +lxc-attach +lxc-console +lxc-create +liblxc +rpcd-mod-lxc +getopt +LUCI_DEPENDS:=+luci-mod-admin-full +lxc +lxc-attach +lxc-console +lxc-create +liblxc +rpcd-mod-lxc +getopt +!LXC_BUSYBOX_OPTIONS:tar LUCI_PKGARCH:=all PKG_MAINTAINER:=Petar Koretic <petar.koretic@sartura.hr> diff --git a/applications/luci-app-lxc/luasrc/controller/lxc.lua b/applications/luci-app-lxc/luasrc/controller/lxc.lua index cc490f0b81..c7fe63f87b 100644 --- a/applications/luci-app-lxc/luasrc/controller/lxc.lua +++ b/applications/luci-app-lxc/luasrc/controller/lxc.lua @@ -14,74 +14,43 @@ Author: Petar Koretic <petar.koretic@sartura.hr> ]]-- -local uci = require "luci.model.uci" -local util = require "luci.util" -local nixio = require "nixio" - module("luci.controller.lxc", package.seeall) -function fork_exec(command) - local pid = nixio.fork() - if pid > 0 then - return - elseif pid == 0 then - -- change to root dir - nixio.chdir("/") - - -- patch stdin, out, err to /dev/null - local null = nixio.open("/dev/null", "w+") - if null then - nixio.dup(null, nixio.stderr) - nixio.dup(null, nixio.stdout) - nixio.dup(null, nixio.stdin) - if null:fileno() > 2 then - null:close() - end - end +local uci = require "luci.model.uci".cursor() +local util = require "luci.util" +local fs = require "nixio" - -- replace with target command - nixio.exec("/bin/sh", "-c", command) +function index() + if not nixio.fs.access("/etc/config/lxc") then + return end -end -function index() page = node("admin", "services", "lxc") page.target = cbi("lxc") page.title = _("LXC Containers") page.order = 70 - page = entry({"admin", "services", "lxc_create"}, call("lxc_create"), nil) - page.leaf = true - - page = entry({"admin", "services", "lxc_action"}, call("lxc_action"), nil) - page.leaf = true - - page = entry({"admin", "services", "lxc_get_downloadable"}, call("lxc_get_downloadable"), nil) - page.leaf = true - - page = entry({"admin", "services", "lxc_configuration_get"}, call("lxc_configuration_get"), nil) - page.leaf = true - - page = entry({"admin", "services", "lxc_configuration_set"}, call("lxc_configuration_set"), nil) - page.leaf = true - + entry({"admin", "services", "lxc_create"}, call("lxc_create"), nil).leaf = true + entry({"admin", "services", "lxc_action"}, call("lxc_action"), nil).leaf = true + entry({"admin", "services", "lxc_get_downloadable"}, call("lxc_get_downloadable"), nil).leaf = true + entry({"admin", "services", "lxc_configuration_get"}, call("lxc_configuration_get"), nil).leaf = true + entry({"admin", "services", "lxc_configuration_set"}, call("lxc_configuration_set"), nil).leaf = true end function lxc_get_downloadable() local target = lxc_get_arch_target() local templates = {} + local ssl_status = lxc_get_ssl_status() - local f = io.popen('sh /usr/share/lxc/templates/lxc-download --list --no-validate --server %s' - % util.shellquote(uci.cursor():get("lxc", "lxc", "url")), 'r') - + local f = io.popen('sh /usr/share/lxc/templates/lxc-download --list %s --server %s 2>/dev/null' + %{ ssl_status, util.shellquote(uci:get("lxc", "lxc", "url")) }, 'r') local line for line in f:lines() do local dist, version, dist_target = line:match("^(%S+)%s+(%S+)%s+(%S+)%s+default%s+%S+$") - if dist and version and dist_target == target then + if dist and version and dist_target and dist_target == target then templates[#templates+1] = "%s:%s" %{ dist, version } end end - f:close() luci.http.prepare_content("application/json") @@ -91,23 +60,26 @@ end function lxc_create(lxc_name, lxc_template) luci.http.prepare_content("text/plain") - if not pcall(dofile, "/etc/openwrt_release") then - return luci.http.write("1") + local check = lxc_get_config_path() + if not check then + return end - local lxc_dist, lxc_release = lxc_template:match("^(.+):(.+)$") + local ssl_status = lxc_get_ssl_status() + local src_err + local lxc_dist, lxc_release = lxc_template:match("^(.+):(.+)$") luci.http.write(util.ubus("lxc", "create", { name = lxc_name, template = "download", args = { - "--server", uci.cursor():get("lxc", "lxc", "url"), - "--no-validate", + "--server", uci:get("lxc", "lxc", "url"), "--dist", lxc_dist, "--release", lxc_release, - "--arch", lxc_get_arch_target() + "--arch", lxc_get_arch_target(), + ssl_status } - })) + }), src_err) end function lxc_action(lxc_action, lxc_name) @@ -121,11 +93,28 @@ function lxc_get_config_path() local f = io.open("/etc/lxc/lxc.conf", "r") local content = f:read("*all") f:close() + local ret = content:match('^%s*lxc.lxcpath%s*=%s*([^%s]*)') if ret then - return ret .. "/" + if nixio.fs.access(ret) then + local min_space = tonumber(uci:get("lxc", "lxc", "min_space")) or 100000 + local free_space = tonumber(util.exec("df " ..ret.. " | awk '{if(NR==2)print $4}'")) + if free_space and free_space >= min_space then + local min_temp = tonumber(uci:get("lxc", "lxc", "min_temp")) or 100000 + local free_temp = tonumber(util.exec("df /tmp | awk '{if(NR==2)print $4}'")) + if free_temp and free_temp >= min_temp then + return ret .. "/" + else + util.perror("lxc error: not enough temporary space (< " ..min_temp.. " KB)") + end + else + util.perror("lxc error: not enough space (< " ..min_space.. " KB)") + end + else + util.perror("lxc error: directory not found") + end else - return "/srv/lxc/" + util.perror("lxc error: config path is empty") end end @@ -142,15 +131,16 @@ end function lxc_configuration_set(lxc_name) luci.http.prepare_content("text/plain") - local lxc_configuration = luci.http.formvalue("lxc_configuration") - + local lxc_configuration = luci.http.formvalue("lxc_conf") if lxc_configuration == nil then - return luci.http.write("1") + util.perror("lxc error: config formvalue is empty") + return end local f, err = io.open(lxc_get_config_path() .. lxc_name .. "/config","w+") if not f then - return luci.http.write("2") + util.perror("lxc error: config file not found") + return end f:write(lxc_configuration) @@ -160,7 +150,7 @@ function lxc_configuration_set(lxc_name) end function lxc_get_arch_target() - local target = nixio.uname().machine + local target = fs.uname().machine local target_map = { armv5 = "armel", armv6 = "armel", @@ -168,13 +158,21 @@ function lxc_get_arch_target() armv8 = "arm64", x86_64 = "amd64" } - local k, v for k, v in pairs(target_map) do - if target:find(k) then + if target:find("^" ..k.. "$") then return v end end - return target end + +function lxc_get_ssl_status() + local ssl_enabled = uci:get("lxc", "lxc", "ssl_enabled") + local ssl_status = "--no-validate" + + if ssl_enabled and ssl_enabled == "1" then + ssl_status = "" + end + return ssl_status +end diff --git a/applications/luci-app-lxc/luasrc/model/cbi/lxc.lua b/applications/luci-app-lxc/luasrc/model/cbi/lxc.lua index ac0fdff332..8a8fc2be0d 100644 --- a/applications/luci-app-lxc/luasrc/model/cbi/lxc.lua +++ b/applications/luci-app-lxc/luasrc/model/cbi/lxc.lua @@ -14,18 +14,35 @@ Author: Petar Koretic <petar.koretic@sartura.hr> ]]-- -local fs = require "nixio.fs" - -m = Map("lxc", translate("LXC Containers")) - -if fs.access("/etc/config/lxc") then - m:section(SimpleSection).template = "lxc" - - s = m:section(TypedSection, "lxc", translate("Options")) - s.anonymous = true - s.addremove = false - - s:option(Value, "url", translate("Containers URL")) -end +m = Map("lxc", translate("LXC Containers"), + translate("<b>Please note:</b> For LXC Containers you need a custom OpenWrt image.<br />") + .. translate("The image should include at least support for 'kernel cgroups', 'kernel namespaces' and 'miscellaneous LXC related options'.")) +m:section(SimpleSection).template = "lxc" + +s = m:section(TypedSection, "lxc", translate("Options")) +s.anonymous = true + +o1 = s:option(Value, "url", translate("Containers URL")) +o1:value("images.linuxcontainers.org") +o1:value("repo.turris.cz/lxc", "repo.turris.cz/lxc (SSL req.)") +o1.default = "images.linuxcontainers.org" +o1.rmempty = false + +o2 = s:option(Flag, "ssl_enabled", translate("Enable SSL"), + translate("Enable optional SSL encryption support. This requires additional packages like 'wget', 'ca-certificates', 'gnupg' and 'gnupg-utils'.")) +o2.default = o2.disabled +o2.rmempty = false + +o3 = s:option(Value, "min_space", translate("Free Space Threshold"), + translate("Minimum required free space for LXC Container creation in KB")) +o3.default = "100000" +o3.datatype = "min(50000)" +o3.rmempty = false + +o4 = s:option(Value, "min_temp", translate("Free Temp Threshold"), + translate("Minimum required free temp space for LXC Container creation in KB")) +o4.default = "100000" +o4.datatype = "min(50000)" +o4.rmempty = false return m diff --git a/applications/luci-app-lxc/luasrc/view/lxc.htm b/applications/luci-app-lxc/luasrc/view/lxc.htm index edfff8e063..e703d6c882 100644 --- a/applications/luci-app-lxc/luasrc/view/lxc.htm +++ b/applications/luci-app-lxc/luasrc/view/lxc.htm @@ -14,16 +14,21 @@ Author: Petar Koretic <petar.koretic@sartura.hr> -%> +<%- +local fs = require "nixio" +local target = fs.uname().machine +-%> + <fieldset class="cbi-section"> <legend><%:Available Containers%></legend> <div class="cbi-section-node"> - <table id="t_lxc_list" class="cbi-section-table"> - <tr class="cbi-section-table-titles"> - <th class="cbi-section-table-cell"><%:Name%></th> - <th class="cbi-section-table-cell"><%:Status%></th> - <th class="cbi-section-table-cell"><%:Actions%></th> - </tr> - </table> + <div class="table cbi-section-table" id="t_lxc_list"> + <div class="tr cbi-section-table-titles"> + <div class="th cbi-section-table-cell"><%:Name%></div> + <div class="th cbi-section-table-cell"><%:Status%></div> + <div class="th cbi-section-table-cell"><%:Actions%></div> + </div> + </div> </div> </fieldset> @@ -31,30 +36,25 @@ Author: Petar Koretic <petar.koretic@sartura.hr> <span id="lxc-list-output"></span> </fieldset> -<hr/> +<hr /> <fieldset class="cbi-section"> <legend><%:Create New Container%></legend> <div class="cbi-section-node"> - <table id="t_lxc_create" class="cbi-section-table"> - <tr class="cbi-section-table-titles"> - <th class="cbi-section-table-cell"><%:Name%></th> - <th class="cbi-section-table-cell"><%:Template%></th> - <th class="cbi-section-table-cell"><%:Actions%></th> - </tr> - <tr id="tr_holder"> - <td> - <input type="text" id="tx_name" placeholder="<%:Enter new name%>" value='' /> - </td> - <td> - <select id="s_template" class="cbi-input-select cbi-button"> - </select> - </td> - <td> - <input type="button" id="bt_create" value="<%:Create%>" onclick="lxc_create(tr_holder)" class="cbi-button cbi-button-add" /> + <div class="table cbi-section-table" id="t_lxc_create"> + <div class="tr cbi-section-table-titles"> + <div class="th cbi-section-table-cell"><%:Name%></div> + <div class="th cbi-section-table-cell"><%:Template%></div> + <div class="th cbi-section-table-cell"><%:Actions%></div> + </div> + <div class="tr cbi-section-table-row" id="div_create"> + <div class="td"><input class="cbi-input-text" type="text" id="tx_name" placeholder="<%:Enter new name%>" value='' /></div> + <div class="td"><select id="s_template" class="cbi-input-select cbi-button"></select></div> + <div class="td"> + <input type="button" id="bt_create" value="<%:Create%>" onclick="lxc_create()" class="cbi-button cbi-button-add" /> <span id="lxc-add-loader" style="display:inline-block; width:16px; height:16px; margin:0 5px"></span> - </td> - </tr> - </table> + </div> + </div> + </div> </div> </fieldset> @@ -62,298 +62,324 @@ Author: Petar Koretic <petar.koretic@sartura.hr> <span id="lxc-add-output"></span> </fieldset> -<hr/> +<hr /> <script type="text/javascript" src="<%=resource%>/cbi.js"></script> -<script type="text/javascript">//<![CDATA[ - - window.img = { "red" : "<%=resource%>/cbi/red.gif", "green" : "<%=resource%>/cbi/green.gif", "purple" : "<%=resource%>/cbi/purple.gif" } - window.states = { "STOPPED" : "red", "RUNNING" : "green", "FROZEN" : "purple"} - - var t_lxc_list = document.getElementById('t_lxc_list'); - var loader_html = '<img src="<%=resource%>/icons/loading.gif" alt="<%:Loading%>" width="16" height="16" style="vertical-align:middle" /> '; - var timeout_msg = 0 - var output_list = document.getElementById("lxc-list-output") - var output_add = document.getElementById("lxc-add-output") - var loader_add = document.getElementById("lxc-add-loader") - - function lxc_create(tr) +<script type="text/javascript"> +//<![CDATA[ + window.img = { "red" : "<%=resource%>/cbi/red.gif", "green" : "<%=resource%>/cbi/green.gif", "purple" : "<%=resource%>/cbi/purple.gif" }; + window.states = { "STOPPED" : "red", "RUNNING" : "green", "FROZEN" : "purple" }; + + var t_lxc_list = document.getElementById('t_lxc_list'); + var loader_html = '<img src="<%=resource%>/icons/loading.gif" alt="<%:Loading%>" width="16" height="16" style="vertical-align:middle" />'; + var output_list = document.getElementById("lxc-list-output"); + var output_add = document.getElementById("lxc-add-output"); + var loader_add = document.getElementById("lxc-add-loader"); + var div_create = document.getElementById("div_create"); + var bt_create = div_create.querySelector("#bt_create"); + + bt_create.disabled = true; + info_message(output_add, "Template download in progress, please be patient!"); + + function lxc_create() { - var lxc_name = tr.querySelector("#tx_name").value.trim() - var lxc_template = tr.querySelector("#s_template").value - var bt_create = tr.querySelector("#bt_create") + var lxc_name = div_create.querySelector("#tx_name").value.replace(/[\s!@#$%^&*()+=\[\]{};':"\\|,<>\/?]/g,''); + var lxc_template = div_create.querySelector("#s_template").value; if (t_lxc_list.querySelector("[data-id='" + lxc_name + "']") != null) - return info_message(output_add, "Container with that name already exists!", 4000) + { + return info_message(output_add, "Container with that name already exists!", 2000); + } - bt_create.disabled = true - output_add.innerHTML = '' + bt_create.disabled = true; + output_add.innerHTML = ''; + + if (!lxc_template) + { + return set_no_template(); + } if (!lxc_name || !lxc_name.length) { - bt_create.disabled = false - return info_message(output_add, "Name cannot be empty!", 4000) + bt_create.disabled = false; + return info_message(output_add, "The 'Name' field must not be empty!", 2000); } - loading(loader_add) + loading(loader_add); new XHR().get('<%=luci.dispatcher.build_url("admin", "services")%>/lxc_create/' + '%h/%h'.format(lxc_name, lxc_template) , null, function(x) { - bt_create.disabled = false - loading(loader_add, 0) + bt_create.disabled = false; + loading(loader_add, 0); if (!x) - info_message(output_add, "Container creation failed!") + { + info_message(output_add, "Container creation failed!", 2000); + } }) } function lxc_create_template(lxc_name, lxc_state) { - var info_row = t_lxc_list.querySelector("#empty") - if (info_row) - t_lxc_list.deleteRow(1) - - var actions = '' - actions += '<input type="button" onclick="action_handler(this)" data-action="start" value="<%:Start%>" class="cbi-button cbi-button-apply" />' - actions+= '<input type="button" onclick="action_handler(this)" data-action="stop" value="<%:Stop%>" class="cbi-button cbi-button-reset" />' - actions+= '<input type="button" onclick="action_handler(this)" data-action="destroy" value="<%:Delete%>" class="cbi-button cbi-button-remove" />' - actions+= ' <select class="cbi-input-select cbi-button" onchange="action_more_handler(this)">\ - <option selected disabled>more</option>\ + if (document.getElementById(lxc_name)) + { + return; + } + + info_message(output_list, ""); + var actions = ''; + actions += '<input type="button" onclick="action_handler(this)" data-action="start" value="<%:Start%>" class="cbi-button cbi-button-apply" />'; + actions += ' <input type="button" onclick="action_handler(this)" data-action="stop" value="<%:Stop%>" class="cbi-button cbi-button-reset" />'; + actions += ' <input type="button" onclick="action_handler(this)" data-action="destroy" value="<%:Delete%>" class="cbi-button cbi-button-remove" />'; + actions += ' <select class="cbi-input-select cbi-button" style="width:10em" onchange="action_more_handler(this)">\ + <option selected="selected" disabled="disabled">more</option>\ <option>configure</option>\ <option>freeze</option>\ <option>unfreeze</option>\ <option>reboot</option>\ - </select>' - actions+= '<span data-loader style="display:inline-block; width:16px; height:16px; margin:0 5px"></span>' - - var row = t_lxc_list.insertRow(-1) - var cell = row.insertCell(-1) - cell.innerHTML = '%q%h%q'.format("<strong>", lxc_name, "</strong>") - cell.width = "30%" - cell.setAttribute("data-id", lxc_name) - - cell = row.insertCell(-1) - cell.width = "20%" - cell.innerHTML = "<img src='"+window.img[lxc_state]+"'/>" - - cell = row.insertCell(-1) - cell.width = "50%" - cell.innerHTML = actions + </select>'; + actions += '<span data-loader="" style="display:inline-block; width:16px; height:16px; margin:0 5px"></span>'; + + var div0 = document.createElement("div"); + div0.className = "tr cbi-section-table-row"; + div0.id = lxc_name; + div0.setAttribute("data-id", lxc_name); + + var div1 = document.createElement("div"); + div1.className = "td"; + div1.style.width = "30%"; + div1.innerHTML = '%q%h%q'.format("<strong>", lxc_name, "</strong>"); + + var div2 = document.createElement("div"); + div2.className = "td"; + div2.style.width = "20%"; + div2.innerHTML = "<img src='"+window.img[lxc_state]+"'/>"; + + var div3 = document.createElement("div"); + div3.className = "td"; + div3.style.width = "50%"; + div3.innerHTML = actions + + document.getElementById("t_lxc_list").appendChild(div0); + div0.appendChild(div1); + div0.appendChild(div2); + div0.appendChild(div3); } function action_handler(self) { - var action = self.getAttribute("data-action"); + var bt_action = self; + var action = self.dataset['action']; + var lxc_name = self.parentNode.parentNode.dataset['id']; + var status_img = self.parentNode.parentNode.querySelector('img'); + var loader = self.parentNode.querySelector('[data-loader]'); - var bt_action = self - var lxc_name = self.parentNode.parentNode.children[0].getAttribute('data-id') - var status_img = self.parentNode.parentNode.querySelector('img') - var loader = self.parentNode.querySelector('[data-loader]') - - bt_action.disabled = true + bt_action.disabled = true; if (action == "stop") { - loading(loader) + loading(loader); new XHR().get('<%=luci.dispatcher.build_url("admin", "services")%>/lxc_action/' + '%h/%h'.format(action, lxc_name), null, function(x, ec) { - loading(loader, 0) - bt_action.disabled = false + loading(loader, 0); + bt_action.disabled = false; if (!x || ec) - return info_message(output_list,"Action failed!") - - set_status(status_img, "red") - + { + return info_message(output_list,"Action failed!", 2000); + } + set_status(status_img, "red"); }); } - else if (action == "start") { - loading(loader) + loading(loader); new XHR().get('<%=luci.dispatcher.build_url("admin", "services")%>/lxc_action/' + '%h/%h'.format(action, lxc_name), null, function(x, data) { - loading(loader, 0) - bt_action.disabled = false - - //FIXME: uncomment after fixing 'lxc-start' - if (!x /*|| ec */) - return info_message(output_list,"Action failed!") + loading(loader, 0); + bt_action.disabled = false; - //FIXME: uncomment after fixing 'lxc-start' - //set_status(status_img, "green") + if (!x || data) + { + return info_message(output_list,"Action failed!", 2000); + } + set_status(status_img, "green"); }); } - else if (action == "destroy") { - if (!confirm("This will completely remove LXC container from the disk. Are you sure? (container will be stopped if running)")) - return + var div = self.parentNode.parentNode + var img = div.querySelector('img') + + if (img.getAttribute('src') != window.img["red"]) + { + bt_action.disabled = false; + return info_message(output_list,"Container is still running!", 2000); + } - loading(loader) + if (!confirm("This will completely remove a stopped LXC container from disk. Are you sure?")) + { + bt_action.disabled = false; + return; + } + loading(loader); new XHR().get('<%=luci.dispatcher.build_url("admin", "services")%>/lxc_action/' + '%h/%h'.format(action, lxc_name), null, function(x, ec) { - loading(loader, 0) - bt_action.disabled = false + loading(loader, 0); + bt_action.disabled = false; if (!x || ec) - return info_message(output_list,"Action failed!") - - var row = self.parentNode.parentNode - row.parentNode.removeChild(row) - + { + return info_message(output_list,"Action failed!", 2000); + } + var div = self.parentNode.parentNode; + div.parentNode.removeChild(div); }); } } function lxc_configure_handler(self) { - var td = self.parentNode - var textarea = td.querySelector('[data-id]') - var lxc_name = textarea.getAttribute('data-id') - var lxc_configuration = textarea.value + var div = self.parentNode; + var textarea = div.querySelector('[data-id]'); + var lxc_name = textarea.dataset['id']; + var lxc_conf = textarea.value; - new XHR().post('<%=luci.dispatcher.build_url("admin", "services")%>/lxc_configuration_set/' + lxc_name, "lxc_configuration=" + encodeURIComponent(lxc_configuration) , + new XHR().post('<%=luci.dispatcher.build_url("admin", "services")%>/lxc_configuration_set/' + lxc_name, "lxc_conf=" + encodeURIComponent(lxc_conf), function(x) { if (!x || x.responseText != "0") - return info_message(output_list,"Action failed!") - - info_message(output_list,"LXC configuration updated") - var row = td.parentNode - row.parentNode.removeChild(row) + { + return info_message(output_list,"Action failed!", 2000); + } + info_message(output_list,"LXC configuration updated", 2000); + var rmdiv = div.parentNode; + rmdiv.parentNode.removeChild(rmdiv); }) } - function lxc_rename_template(lxc_name) - { - var h = '\ - <input data-id="'+ lxc_name + '" type="text" placeholder="Enter new name" /> \ - <input data-id="bt_confirm" onclick="lxc_rename_handler(this)" type="button" class="cbi-button" value="Confirm" />' - - return h - } - - function lxc_configure_template(lxc_name, lxc_configuration) + function lxc_configure_template(lxc_name, lxc_conf) { var h = '\ - <textarea data-id="'+ lxc_name + '" rows="20" style="width:100%">'+ lxc_configuration +'</textarea> \ - <input data-id="bt_confirm" onclick="lxc_configure_handler(this)" type="button" class="cbi-button" value="Confirm" />' - - return h + <textarea data-id="' + lxc_name + '" rows="20" style="width:600px;font-family:monospace;white-space:pre;overflow-wrap:normal;overflow-x:scroll;">'+ lxc_conf +'</textarea> \ + <input data-id="bt_confirm" onclick="lxc_configure_handler(this)" type="button" class="cbi-button" value="Confirm" />'; + return h; } function action_more_handler(self) { - var lxc_name = self.parentNode.parentNode.querySelector('[data-id]').getAttribute('data-id') - var loader = self.parentNode.parentNode.querySelector('[data-loader]') + var lxc_name = self.parentNode.parentNode.dataset['id']; + var loader = self.parentNode.querySelector('[data-loader]'); + var option = self.options[self.selectedIndex].text; + self.value = "more"; - var option = self.options[self.selectedIndex].text - - self.value = "more" - - switch (option) + switch(option) { case "configure": - var tr = document.createElement('tr') - var row = self.parentNode.parentNode - var next_row = row.nextSibling - if (next_row && next_row.getAttribute('data-action') !== null) - row.parentNode.removeChild(next_row) + var div0 = document.createElement('div'); + var div1 = self.parentNode.parentNode; + var next_div = div1.nextSibling; + + if (next_div && next_div.dataset['action'] !== null) + { + div1.parentNode.removeChild(next_div); + } new XHR().get('<%=luci.dispatcher.build_url("admin", "services")%>/lxc_configuration_get/' + lxc_name, null, function(x) { - tr.innerHTML="<td colspan='" + row.cells.length + "'>" + lxc_configure_template(lxc_name, x.responseText) + "</td>" - tr.setAttribute('data-action','') - row.parentNode.insertBefore(tr, row.nextSibling) + div0.innerHTML="<div>" + lxc_configure_template(lxc_name, x.responseText) + "</div>"; + div0.setAttribute('data-action',''); + div1.parentNode.insertBefore(div0, div1.nextSibling); }) - - break + break; case "freeze": - var tr = self.parentNode.parentNode - var img = tr.querySelector('img') + var img = self.parentNode.parentNode.querySelector('img'); if(img.getAttribute('src') != window.img["green"]) - return info_message(output_list,"Container is not running!") + { + return info_message(output_list,"Container is not running!", 2000); + } + + loading(loader); - loading(loader) new XHR().get('<%=luci.dispatcher.build_url("admin", "services")%>/lxc_action/' + '%h/%h'.format(option, lxc_name), null, function(x, ec) { loading(loader, 0) if (!x || ec) - return info_message(output_list,"Action failed!") - - set_status(img, "purple") + { + return info_message(output_list,"Action failed!", 2000); + } + set_status(img, "purple"); }) - - break + break; case "unfreeze": - var tr = self.parentNode.parentNode - var img = tr.querySelector('img') - + var img = self.parentNode.parentNode.querySelector('img'); if(img.getAttribute('src') != window.img["purple"]) - return info_message(output_list,"Container is not frozen!") + { + return info_message(output_list,"Container is not frozen!", 2000); + } + + loading(loader); - loading(loader) new XHR().get('<%=luci.dispatcher.build_url("admin", "services")%>/lxc_action/' + '%h/%h'.format(option, lxc_name), null, function(x, ec) { - loading(loader, 0) + loading(loader, 0); if (!x || ec) - return info_message(output_list,"Action failed!") - - set_status(img, "green") + { + return info_message(output_list,"Action failed!", 2000); + } + set_status(img, "green"); }) - - break + break; case "reboot": - var tr = self.parentNode.parentNode - var img = tr.querySelector('img') + var img = self.parentNode.parentNode.querySelector('img'); if(img.getAttribute('src') != window.img["green"]) - return info_message(output_list,"Container is not running!") + { + return info_message(output_list,"Container is not running!", 2000); + } if (!confirm("Are you sure?")) - return + { + return; + } + + loading(loader); - loading(loader) new XHR().get('<%=luci.dispatcher.build_url("admin", "services")%>/lxc_action/' + '%h/%h'.format(option, lxc_name), null, function(x, ec) { loading(loader, 0) if (!x || ec) - return info_message(output_list,"Action failed!") - - info_message(output_list,"LXC rebooted") + { + return info_message(output_list,"Action failed!", 2000); + } + info_message(output_list,"LXC container rebooted", 2000); }) - break + break; } - } - function set_empty(t_lxc_list) + function set_no_container() { - if (document.getElementById('empty') !== null) - return - - var row_count = t_lxc_list.rows.length; - while(--row_count) t_lxc_list.deleteRow(row_count); + info_message(output_list, "There are no containers available yet."); + } - var row = t_lxc_list.insertRow(-1); - row.id = 'empty' - var cell = row.insertCell(0); - cell.colSpan = 4; - cell.innerHTML = '<em><br />There are no containers available yet.</em>'; + function set_no_template() + { + bt_create.disabled = true; + info_message(output_add, "There are no templates for your architecture (<%=target%>) available, please select another containers URL."); } function lxc_list_update() @@ -361,90 +387,108 @@ Author: Petar Koretic <petar.koretic@sartura.hr> XHR.poll(4, '<%=luci.dispatcher.build_url("admin", "services")%>/lxc_action/list', null, function(x, data) { - if (!x) return; - - var lxc_count = Object.keys(data).length - if (!data || !lxc_count) - return set_empty(t_lxc_list) + if (!x || !data) + { + return; + } - if (document.getElementById('empty') !== null) - t_lxc_list.deleteRow(1); + var lxc_count = Object.keys(data).length; + if (!lxc_count) + { + return set_no_container(); + } - var lxcs = t_lxc_list.querySelectorAll('td[data-id]') - var lxc_name_table = {} + var lxcs = t_lxc_list.querySelectorAll('td[data-id]'); + var lxc_name_div = {}; for (var i = 0, len = lxcs.length; i < len; i++) { - var lxc_name = lxcs[i].getAttribute('data-id') + var lxc_name = lxcs[i].dataset['id']; if (!(lxc_name in data)) { - var row = t_lxc_list.querySelector("[data-id='" + lxc_name + "']").parentNode - row.parentNode.removeChild(row) - continue + var div = t_lxc_list.querySelector("[data-id='" + lxc_name + "']").parentNode; + div.parentNode.removeChild(div); + continue; } - - lxc_name_table[lxc_name] = lxcs[i].parentNode.querySelector('img') + lxc_name_div[lxc_name] = lxcs[i].parentNode.querySelector('img'); } for(var key in data) { - var lxc_name = key - var state = window.states[data[key]] - - if (!(lxc_name in lxc_name_table)) - lxc_create_template(lxc_name, state) + var lxc_name = key; + var state = window.states[data[key]]; - else if (state != get_status(lxc_name_table[lxc_name])) - set_status(lxc_name_table[lxc_name], state) + if (!(lxc_name in lxc_name_div)) + { + lxc_create_template(lxc_name, state); + } + else if (state != get_status(lxc_name_div[lxc_name])) + { + set_status(lxc_name_div[lxc_name], state); + } } - }) } function loading(elem, state) { - state = (typeof state === 'undefined') ? 1 : state - + state = (typeof state === 'undefined') ? 1 : state; if (state === 1) - elem.innerHTML = loader_html + { + elem.innerHTML = loader_html; + } else - setTimeout(function() { elem.innerHTML = ''}, 1000) + { + setTimeout(function() { elem.innerHTML = ''}, 2000); + } } function set_status(elem, state) { - state = (typeof state === 'undefined') ? 1 : state - - setTimeout(function() { elem.setAttribute('src', window.img[state])}, 300) + state = (typeof state === 'undefined') ? 1 : state; + setTimeout(function() { elem.setAttribute('src', window.img[state])}, 300); } function get_status(elem) { - var src = elem.getAttribute('src') - + var src = elem.getAttribute('src'); for (var i in img) { if (img[i] == src) - return i + { + return i; + } } } function info_message(output, msg, timeout) { - timeout = timeout || 3000 - output.innerHTML = msg - clearTimeout(timeout_msg) - timeout_msg = setTimeout(function(){ output.innerHTML=""}, timeout); + timeout = timeout || 0; + output.innerHTML = '<em>' + msg + '</em>'; + if (timeout > 0) + { + setTimeout(function(){ output.innerHTML=""}, timeout); + } } - lxc_list_update() - new XHR().get('<%=luci.dispatcher.build_url("admin", "services")%>/lxc_get_downloadable', null, function(x, data) { - if (!x) return; + if (!x) + { + return; + } + + if (!data) + { + return set_no_template(); + } + + var lxc_count = Object.keys(data).length; + if (!lxc_count) + { + return set_no_template(); + } - var lxc_count = Object.keys(data).length - if (!data || !lxc_count) return; var select = document.getElementById("s_template"); for(var key in data) { @@ -453,6 +497,11 @@ Author: Petar Koretic <petar.koretic@sartura.hr> option.text = data[key].replace(/[_:]/g, ' '); select.add(option, -1); } + + info_message(output_add, ""); + bt_create.disabled = false; }) -//]]></script> + lxc_list_update(); +//]]> +</script> diff --git a/applications/luci-app-mwan3/po/ja/mwan3.po b/applications/luci-app-mwan3/po/ja/mwan3.po index cfbf5ac464..a5826926dd 100644 --- a/applications/luci-app-mwan3/po/ja/mwan3.po +++ b/applications/luci-app-mwan3/po/ja/mwan3.po @@ -7,7 +7,7 @@ msgstr "" "Language-Team: \n" "MIME-Version: 1.0\n" "Content-Transfer-Encoding: 8bit\n" -"X-Generator: Poedit 2.0.3\n" +"X-Generator: Poedit 2.0.7\n" "Last-Translator: INAGAKI Hiroshi <musashino.open@gmail.com>\n" "Plural-Forms: nplurals=1; plural=0;\n" "Language: ja\n" @@ -44,7 +44,7 @@ msgid "Check IP rules" msgstr "IP ルールのチェック" msgid "Check link quality" -msgstr "" +msgstr "リンク品質のチェック" msgid "Check routing table" msgstr "ルーティング テーブルのチェック" @@ -59,7 +59,7 @@ msgid "Destination port" msgstr "宛先ポート" msgid "Detail" -msgstr "" +msgstr "詳細" msgid "Diagnostics" msgstr "診断機能" @@ -80,7 +80,7 @@ msgid "Enter value in hex, starting with <code>0x</code>" msgstr "<code>0x</code> で始まる16進数の値を入力してください。" msgid "Execute" -msgstr "" +msgstr "実行" msgid "Expect interface state on up event" msgstr "Up イベント時に予想されるインターフェースの状態です。" @@ -92,10 +92,12 @@ msgid "Firewall mask" msgstr "ファイアウォール マスク" msgid "Flush conntrack table" -msgstr "" +msgstr "conntrack テーブルのクリア" msgid "Flush global firewall conntrack table on interface events" msgstr "" +"インターフェース イベント時にグローバル ファイアウォール conntrack テーブルを" +"クリアします。" msgid "Globals" msgstr "全般" @@ -107,7 +109,7 @@ msgid "Hotplug ifup" msgstr "ホットプラグ ifup" msgid "INFO: MWAN not running" -msgstr "" +msgstr "情報: MWAN は実行されていません" msgid "IPset" msgstr "IPset" @@ -160,28 +162,28 @@ msgid "Local source interface" msgstr "" msgid "MWAN - Globals" -msgstr "" +msgstr "MWAN - グローバル" msgid "MWAN - Interfaces" -msgstr "" +msgstr "MWAN - インターフェース" msgid "MWAN - Members" -msgstr "" +msgstr "MWAN - メンバー" msgid "MWAN - Notification" -msgstr "" +msgstr "MWAN - 通知" msgid "MWAN - Policies" -msgstr "" +msgstr "MWAN - ポリシー" msgid "MWAN - Rules" -msgstr "" +msgstr "MWAN - ルール" msgid "MWAN Interface Configuration - %s" msgstr "MWAN インターフェース設定 - %s" msgid "MWAN Interfaces" -msgstr "" +msgstr "MWAN インターフェース" msgid "MWAN Member Configuration - %s" msgstr "MWAN メンバー設定 - %s" @@ -193,13 +195,13 @@ msgid "MWAN Rule Configuration - %s" msgstr "MWAN ルール設定 - %s" msgid "MWAN Status - Detail" -msgstr "" +msgstr "MWAN ステータス - 詳細" msgid "MWAN Status - Diagnostics" -msgstr "" +msgstr "MWAN ステータス - 診断" msgid "MWAN Status - Troubleshooting" -msgstr "" +msgstr "MWAN ステータス - トラブルシューティング" msgid "" "MWAN supports up to 252 physical and/or logical interfaces<br />MWAN " @@ -218,10 +220,10 @@ msgstr "" "シー、ルールと同じ名前を使用することはできません。" msgid "Max packet latency [ms]" -msgstr "" +msgstr "最大パケットレイテンシ [ms]" msgid "Max packet loss [%]" -msgstr "" +msgstr "最大パケットロス [%]" msgid "" "May be entered as a single or multiple port(s) (eg \"22\" or \"80,443\") or " @@ -256,10 +258,10 @@ msgid "Metric" msgstr "メトリック" msgid "Min packet latency [ms]" -msgstr "" +msgstr "最小パケットレイテンシ [ms]" msgid "Min packet loss [%]" -msgstr "" +msgstr "最小パケットロス [%]" msgid "" "Name of IPset rule. Requires IPset rule in /etc/dnsmasq.conf (eg \"ipset=/" @@ -275,7 +277,7 @@ msgid "No MWAN interfaces found" msgstr "MWAN インターフェースが見つかりません" msgid "Notification" -msgstr "" +msgstr "通知" msgid "Offline" msgstr "オフライン" @@ -357,6 +359,16 @@ msgid "" "z, 0-9, _ and no spaces<br />Rules may not share the same name as configured " "interfaces, members or policies" msgstr "" +"ルールは、どのトラフィックが特定の MWAN ポリシーを使用するかを指定します<br /" +">ルールは IP アドレスやポート、プロトコルに基づいています<br />ルールは上から" +"下へマッチングが行われます<br />合致したルールより下のルールは無視されます" +"<br />いずれのルールにもマッチしないトラフィックは、メインのルーティングテー" +"ブルを使用してルーティングされます<br />既知(デフォルト以外)のネットワーク" +"へのトラフィックは、メインのルーティングテーブルによって制御されます<br />ト" +"ラフィックがルールに合致しても、全 WAN インターフェースが down の場合は " +"blackhole 状態となります<br />名前は A-Z, a-z, 0-9, _ を含むことができます" +"が、スペースは使用できません<br />ルールは、設定済みのインターフェースやメン" +"バー、ポリシーと同じ名前を使用することはできません。" msgid "Seconds. Acceptable values: 1-1000000. Defaults to 600 if not set" msgstr "秒。利用可能な値: 1-1000000。空欄の場合のデフォルト値は600です。" @@ -377,7 +389,7 @@ msgid "Supports CIDR notation (eg \"192.168.100.0/24\") without quotes" msgstr "CIDR 表記のサポート(例: \"192.168.100.0/24\")" msgid "Task" -msgstr "" +msgstr "タスク" msgid "There are currently %d of %d supported interfaces configured" msgstr "現在、%d 個中 %d 個のサポートされたインターフェースが設定済みです。" @@ -412,6 +424,21 @@ msgid "" "Physical device name which interface went up or down (e.g. \"eth0\" or " "\"wwan0\")<br /><br />" msgstr "" +"このセクションでは、 \"/etc/mwan3.user\" の内容を変更することができます。" +"<br />このファイルも sysupgrade の際に保持されます。<br /><br />注意: <br />" +"このファイルはシェルスクリプトとして解釈されます。<br />最初の行は "#!/" +"bin/sh" である必要があります(クォーテーション不要)。<br /># で始まる行" +"はコメントであり、実行されません。<br />mwan3 のカスタム動作をここに入力して" +"ください。<br />これらは、mwan3 で有効なインターフェースの<br /> netifd " +"hotplug インターフェース イベント毎に実行されます。<br /><br />このスクリプト" +"に受け渡される主に3つの環境変数が利用できます。<br /><br />$ACTION<br />* " +"\"ifup\" は netifd と mwan3track により呼び出されます<br />* \"ifdown\" は " +"netifd と mwan3track により呼び出されます<br />* \"connected\" はトラッキング" +"が成功した際に mwan3track にのみにより呼び出されます<br />* \"disconnected\" " +"は トラッキングが失敗した際に mwan3track のみにより呼び出されます<br />" +"$INTERFACE up または down したインターフェース名(例: \"wan\" や \"wwan\")" +"<br />$DEVICE up または down したインターフェースの物理デバイス名(例: " +"\"eth0\" や \"wwan0\")<br /><br />" msgid "Tracking hostname or IP address" msgstr "追跡ホスト名または IP アドレス" @@ -441,36 +468,42 @@ msgstr "" "インターフェースの IP アドレスが使用されます。" msgid "View the content of /etc/protocols for protocol description" -msgstr "" +msgstr "プロトコルの説明については、 /etc/protocols の内容を確認してください" msgid "WARNING: %d interfaces are configured exceeding the maximum of %d!" msgstr "" "警告: %d 個のインターフェースが、最大個数の %d 個 を超えて設定されています!" msgid "WARNING: Interface %s are not found in /etc/config/network" -msgstr "" +msgstr "警告: インターフェース %s が /etc/config/network に見つかりません" msgid "WARNING: Interface %s has a duplicate metric %s configured" -msgstr "" +msgstr "警告: インターフェース %s に重複するメトリック %s が設定されています" msgid "" "WARNING: Interface %s has a higher reliability requirement than tracking " "hosts (%d)" msgstr "" +"警告: インターフェース %s は追跡ホスト数 (%d) よりも高い追跡信頼性の値が設定" +"されています" msgid "WARNING: Interface %s has no default route in the main routing table" msgstr "" +"警告: インターフェース %s はメインのルーティング テーブル内でデフォルトルート" +"がありません" msgid "WARNING: Policy %s has exceeding the maximum name of 15 characters" -msgstr "" +msgstr "警告: ポリシー %s の名前は15文字の最大文字数を超えています" msgid "" "WARNING: Rule %s have a port configured with no or improper protocol " "specified!" msgstr "" +"警告: ルール %s はプロトコル指定が不適切、または無いポートが設定されていま" +"す!" msgid "Waiting for command to complete..." -msgstr "" +msgstr "コマンドを実行中です..." msgid "Weight" msgstr "ウエイト" @@ -504,289 +537,3 @@ msgstr "never" msgid "unreachable (reject)" msgstr "unreachable (reject)" - -#~ msgid "Online (tracking active)" -#~ msgstr "オンライン(追跡実行中)" - -#~ msgid "MWAN Interface Live Status" -#~ msgstr "MWAN インターフェース Live ステータス" - -#~ msgid "Online (tracking off)" -#~ msgstr "オンライン(追跡オフ)" - -#~ msgid "" -#~ "This section allows you to modify the content of \"/etc/mwan3.user\".<br /" -#~ ">The file is also preserved during sysupgrade.<br /><br />Notes:<br /" -#~ ">This file is interpreted as a shell script.<br />The first line of the " -#~ "script must be "#!/bin/sh" without quotes.<br />Lines beginning " -#~ "with # are comments and are not executed.<br />Put your custom mwan3 " -#~ "action here, they will<br />be executed with each netifd hotplug " -#~ "interface event<br />on interfaces for which mwan3 is enabled.<br /><br /" -#~ ">There are three main environment variables that are passed to this " -#~ "script.<br /><br />$ACTION Either \"ifup\" or \"ifdown\"<br />$INTERFACE " -#~ "Name of the interface which went up or down (e.g. \"wan\" or \"wwan" -#~ "\")<br />$DEVICE Physical device name which interface went up or down (e." -#~ "g. \"eth0\" or \"wwan0\")<br /><br />" -#~ msgstr "" -#~ "このセクションでは、 \"/etc/mwan3.user\" の内容を変更することができます。" -#~ "<br />このファイルは、 sysupgrade 時に保持されます。<br /><br />注意: " -#~ "<br />このファイルは、シェルスクリプトとして解釈されます。<br />スクリプト" -#~ "の1行目は、"#!bin/sh" である必要があります(クォーテーション不" -#~ "要)。<br /># で始まる行はコメントであり、実行されません。<br />mwan3 のカ" -#~ "スタム動作をここに入力してください。これらは、 mwan3 が有効なインター" -#~ "フェースの<br />netifd ホットプラグ インターフェース イベント毎に実行され" -#~ "ます。<br /><br />主に3つの環境変数が利用可能です。<br /><br />$ACTION - " -#~ "\"ifup\" および \"ifdown\"<br />$INTERFACE - Up または Down が行われたイン" -#~ "ターフェース名(例: \"wan\" や \"wwan\")<br />$DEVICE - Up または Down が" -#~ "行われた物理デバイス名(例: \"eth0\" や \"wwan0\")<br /><br />" - -#~ msgid "Currently Configured Interfaces" -#~ msgstr "設定済みインターフェース" - -#~ msgid "Currently Configured Members" -#~ msgstr "設定済みメンバー" - -#~ msgid "Currently Configured Policies" -#~ msgstr "設定済みポリシー" - -#~ msgid "Detailed Status" -#~ msgstr "詳細ステータス" - -#~ msgid "Diagnostic Results" -#~ msgstr "診断結果" - -#~ msgid "Error collecting troubleshooting information" -#~ msgstr "トラブルシューティング情報の収集エラー" - -#~ msgid "Errors" -#~ msgstr "エラー" - -#~ msgid "Globals mwan3 options" -#~ msgstr "MWAN3 全般オプション" - -#~ msgid "Interface Status" -#~ msgstr "インターフェース ステータス" - -#~ msgid "Last 50 MWAN systemlog entries. Newest entries sorted at the top :" -#~ msgstr "直近の MWAN システムログ(50行)です。一番上が最新の行です:" - -#~ msgid "MWAN Detailed Status" -#~ msgstr "MWAN 詳細ステータス" - -#~ msgid "MWAN Interface Configuration" -#~ msgstr "MWAN インターフェース設定" - -#~ msgid "MWAN Interface Diagnostics" -#~ msgstr "MWAN インターフェース診断" - -#~ msgid "MWAN Interface Systemlog" -#~ msgstr "MWAN インターフェース システムログ" - -#~ msgid "MWAN Member Configuration" -#~ msgstr "MWAN メンバー設定" - -#~ msgid "MWAN Policy Configuration" -#~ msgstr "MWAN ポリシー設定" - -#~ msgid "MWAN Rule Configuration" -#~ msgstr "MWAN ルール設定" - -#~ msgid "MWAN Service Control" -#~ msgstr "MWAN サービス コントロール" - -#~ msgid "No MWAN systemlog history found" -#~ msgstr "MWAN システムログの履歴が見つかりません" - -#~ msgid "No detailed status information available" -#~ msgstr "詳細ステータス情報は利用できません" - -#~ msgid "No diagnostic results returned" -#~ msgstr "診断結果がありません" - -#~ msgid "No protocol specified" -#~ msgstr "プロトコルが設定されていません" - -#~ msgid "Restart MWAN" -#~ msgstr "MWAN の再起動" - -#~ msgid "" -#~ "Rules specify which traffic will use a particular MWAN policy based on IP " -#~ "address, port or protocol<br />Rules are matched from top to bottom. " -#~ "Rules below a matching rule are ignored. Traffic not matching any rule is " -#~ "routed using the main routing table<br />Traffic destined for known " -#~ "(other than default) networks is handled by the main routing table. " -#~ "Traffic matching a rule, but all WAN interfaces for that policy are down " -#~ "will be blackholed<br />Names may contain characters A-Z, a-z, 0-9, _ and " -#~ "no spaces<br />Rules may not share the same name as configured " -#~ "interfaces, members or policies" -#~ msgstr "" -#~ "ルールは IP アドレスやポート、プロトコルを基に、トラフィックがどの MWAN ポ" -#~ "リシーを使用するかを設定します。<br />ルールは上から下へマッチングが行わ" -#~ "れ、合致したルールより下のルールは無視されます。全てのルールに合致しないト" -#~ "ラフィックは、メインのルーティング テーブルを使用してルートが決定されま" -#~ "す。<br />既知(デフォルト以外)のネットワークへのトラフィックは、メインの" -#~ "ルーティング テーブルによって制御されます。ルールに合致したトラフィックで" -#~ "も、当該ポリシーの全 WAN インターフェースが Down 状態の場合は blackhole 状" -#~ "態となります。<br />名前は A-Z, a-z, 0-9, _ を含むことができますが、スペー" -#~ "スは使用できません。<br />ルールは、設定済みのインターフェースやメンバー、" -#~ "ポリシーと同じ名前を使用することはできません。" - -#~ msgid "Start MWAN" -#~ msgstr "MWAN の起動" - -#~ msgid "Stop MWAN" -#~ msgstr "MWAN の停止" - -#~ msgid "Tracking IP" -#~ msgstr "追跡 IP" - -#~ msgid "Traffic Rules" -#~ msgstr "トラフィック ルール" - -#~ msgid "Troubleshooting Data" -#~ msgstr "トラブルシューティング データ" - -#~ msgid "View the contents of /etc/protocols for protocol descriptions" -#~ msgstr "" -#~ "プロトコルの説明については、 /etc/protocols の内容を確認してください。" - -#~ msgid "" -#~ "WARNING: Some interfaces are configured incorrectly or not at all in /etc/" -#~ "config/network!" -#~ msgstr "" -#~ "警告: 設定を誤っているか、もしくは完全に設定されていないインターフェースが" -#~ "あります!" - -#~ msgid "" -#~ "WARNING: Some interfaces have a higher reliability requirement than there " -#~ "are tracking IP addresses!" -#~ msgstr "" -#~ "警告: 追跡 IP アドレスの個数より大きい追跡信頼性の値が設定されたインター" -#~ "フェースがあります!" - -#~ msgid "" -#~ "WARNING: Some interfaces have duplicate metrics configured in /etc/config/" -#~ "network!" -#~ msgstr "" -#~ "警告: /etc/config/network で、重複するメトリックを設定されているインター" -#~ "フェースがあります!" - -#~ msgid "" -#~ "WARNING: Some interfaces have no default route in the main routing table!" -#~ msgstr "" -#~ "警告: メインのルーティング テーブルで、デフォルト ルートを設定されていない" -#~ "インターフェースがあります!" - -#~ msgid "" -#~ "WARNING: Some interfaces have no metric configured in /etc/config/network!" -#~ msgstr "" -#~ "警告: /etc/config/network で、メトリックを設定されていないインターフェース" -#~ "があります!" - -#~ msgid "" -#~ "WARNING: Some policies have names exceeding the maximum of 15 characters!" -#~ msgstr "" -#~ "警告: 最大文字数の 15 文字を超える名前が設定されているポリシーがあります!" - -#~ msgid "" -#~ "WARNING: Some rules have a port configured with no or improper protocol " -#~ "specified! Please configure a specific protocol!" -#~ msgstr "" -#~ "警告: 不適切なプロトコルが指定されている、または何も指定されていないポート" -#~ "を設定されたルールがあります!プロトコルを指定し直してください!" - -#~ msgid "" -#~ "WARNING: This and other interfaces have duplicate metrics configured in /" -#~ "etc/config/network!" -#~ msgstr "" -#~ "警告: これと他のインターフェースで重複するメトリックが /etc/config/" -#~ "network に設定されています!" - -#~ msgid "" -#~ "WARNING: This interface has a higher reliability requirement than there " -#~ "are tracking IP addresses!" -#~ msgstr "" -#~ "警告: このインターフェースは、追跡 IP アドレスの個数より大きい追跡信頼性の" -#~ "値を設定されています!" - -#~ msgid "" -#~ "WARNING: This interface has no default route in the main routing table!" -#~ msgstr "" -#~ "警告: このインターフェースは、メインのルーティング テーブルにデフォルト " -#~ "ルートが設定されていません!" - -#~ msgid "" -#~ "WARNING: This interface has no metric configured in /etc/config/network!" -#~ msgstr "" -#~ "警告: このインターフェースは、 /etc/config/network でメトリックが設定され" -#~ "ていません!" - -#~ msgid "" -#~ "WARNING: This interface is configured incorrectly or not at all in /etc/" -#~ "config/network!" -#~ msgstr "" -#~ "警告: このインターフェースは /etc/config/network で設定が誤っているか、も" -#~ "しくは完全に設定されていません!" - -#~ msgid "" -#~ "WARNING: This policy's name is %d characters exceeding the maximum of 15!" -#~ msgstr "" -#~ "警告: このポリシーの名前は、最大文字数 15 文字を超える %d 文字が設定されて" -#~ "います!" - -#~ msgid "" -#~ "WARNING: This rule is incorrectly configured with no or improper protocol " -#~ "specified! Please configure a specific protocol!" -#~ msgstr "" -#~ "警告: このルールは不適切なプロトコルが指定されているか、または何も指定され" -#~ "ていません!プロトコルを指定し直してください!" - -#~ msgid "Waiting for MWAN to %s..." -#~ msgstr "MWAN の %s を待っています..." - -#~ msgid "Waiting for diagnostic results..." -#~ msgstr "診断結果を待っています..." - -#~ msgid "restart" -#~ msgstr "再起動" - -#~ msgid "start" -#~ msgstr "起動" - -#~ msgid "stop" -#~ msgstr "停止" - -#~ msgid "Advanced" -#~ msgstr "詳細設定" - -#~ msgid "Configuration" -#~ msgstr "設定" - -#~ msgid "Hotplug Script" -#~ msgstr "ホットプラグ スクリプト" - -#~ msgid "MWAN Config" -#~ msgstr "MWAN 設定" - -#~ msgid "Network Config" -#~ msgstr "ネットワーク設定" - -#~ msgid "Overview" -#~ msgstr "概要" - -#~ msgid "This section allows you to modify the contents of /etc/config/mwan3" -#~ msgstr "" -#~ "このセクションでは、 /etc/config/mwan3 の内容を変更することができます。" - -#~ msgid "" -#~ "This section allows you to modify the contents of /etc/config/network" -#~ msgstr "" -#~ "このセクションでは、 /etc/config/network の内容を変更することができます。" - -#~ msgid "" -#~ "This section allows you to modify the contents of /etc/config/wireless" -#~ msgstr "" -#~ "このセクションでは、 /etc/config/wireless の内容を変更することができます。" - -#~ msgid "Wireless Config" -#~ msgstr "無線設定" diff --git a/applications/luci-app-noddos/luasrc/view/noddos/clients.htm b/applications/luci-app-noddos/luasrc/view/noddos/clients.htm index f2fb9312a7..4caf3e04e4 100644 --- a/applications/luci-app-noddos/luasrc/view/noddos/clients.htm +++ b/applications/luci-app-noddos/luasrc/view/noddos/clients.htm @@ -38,70 +38,70 @@ <fieldset class="cbi-section"> <legend><%:Recognized Clients%></legend> <div class="cbi-section-node"> - <table class="cbi-section-table"> - <tr class="cbi-section-table-titles"> - <th class="cbi-section-table-cell"><%:Hostname%></th> - <th class="cbi-section-table-cell"><%:IPv4%></th> - <th class="cbi-section-table-cell"><%:MAC%></th> - <th class="cbi-section-table-cell"><%:Manufacturer%></th> - <th class="cbi-section-table-cell"><%:Model%></th> - <th class="cbi-section-table-cell"><%:Class%></th> - </tr> + <div class="table cbi-section-table"> + <div class="tr cbi-section-table-titles"> + <div class="th cbi-section-table-cell"><%:Hostname%></div> + <div class="th cbi-section-table-cell"><%:IPv4%></div> + <div class="th cbi-section-table-cell"><%:MAC%></div> + <div class="th cbi-section-table-cell"><%:Manufacturer%></div> + <div class="th cbi-section-table-cell"><%:Model%></div> + <div class="th cbi-section-table-cell"><%:Class%></div> + </div> <% for i,v in ipairs(devdump) do if v.DeviceProfileUuid ~= "" then %> - <tr class="cbi-section-table-row cbi-rowstyle-<%=(style and 1 or 2)%>"> - <td class="cbi-value-field"><%=v.Hostname%></td> - <td class="cbi-value-field"><%=v.Ipv4Address%></td> - <td class="cbi-value-field"><a href="/cgi-bin/clientdetails?mac=<%=v.MacAddress%>"><%=v.MacAddress%></a></td> - <td class="cbi-value-field"><%=devicevalues[v.DeviceProfileUuid].Manufacturer%></td> - <td class="cbi-value-field"><%=devicevalues[v.DeviceProfileUuid].Model%></td> - <td class="cbi-value-field"><%=devicevalues[v.DeviceProfileUuid].ThingClass%></td> - </tr> + <div class="tr cbi-section-table-row cbi-rowstyle-<%=(style and 1 or 2)%>"> + <div class="td cbi-value-field"><%=v.Hostname%></div> + <div class="td cbi-value-field"><%=v.Ipv4Address%></div> + <div class="td cbi-value-field"><a href="/cgi-bin/clientdetails?mac=<%=v.MacAddress%>"><%=v.MacAddress%></a></div> + <div class="td cbi-value-field"><%=devicevalues[v.DeviceProfileUuid].Manufacturer%></div> + <div class="td cbi-value-field"><%=devicevalues[v.DeviceProfileUuid].Model%></div> + <div class="td cbi-value-field"><%=devicevalues[v.DeviceProfileUuid].ThingClass%></div> + </div> <% style=false end end %> - </table> + </div> </div> </fieldset> <br /> <fieldset class="cbi-section"> <legend><%:Unrecognized Clients%></legend> <div class="cbi-section-node"> - <table class="cbi-section-table"> - <tr class="cbi-section-table-titles"> - <th class="cbi-section-table-cell"><%:Hostname%></th> - <th class="cbi-section-table-cell"><%:IPv4%></th> - <th class="cbi-section-table-cell"><%:MAC%></th> - <th class="cbi-section-table-cell"><%:Manufacturer%></th> - <th class="cbi-section-table-cell"><%:Model%></th> - <th class="cbi-section-table-cell"><%:DhcpVendor%></th> - <th class="cbi-section-table-cell"><%:DhcpHostname%></th> - </tr> + <div class="table cbi-section-table"> + <div class="tr cbi-section-table-titles"> + <div class="th cbi-section-table-cell"><%:Hostname%></div> + <div class="th cbi-section-table-cell"><%:IPv4%></div> + <div class="th cbi-section-table-cell"><%:MAC%></div> + <div class="th cbi-section-table-cell"><%:Manufacturer%></div> + <div class="th cbi-section-table-cell"><%:Model%></div> + <div class="th cbi-section-table-cell"><%:DhcpVendor%></div> + <div class="th cbi-section-table-cell"><%:DhcpHostname%></div> + </div> <% for i,v in ipairs(devdump) do if v.DeviceProfileUuid == "" then %> - <tr class="cbi-section-table-row cbi-rowstyle-<%=(style and 1 or 2)%>"> - <td class="cbi-value-field"><%=v.Hostname%></td> - <td class="cbi-value-field"><%=v.Ipv4Address%></td> - <td class="cbi-value-field"><a href="/cgi-bin/clientdetails?mac=<%=v.MacAddress%>"><%=v.MacAddress%></a></td> - <td class="cbi-value-field"><%=v.SsdpManufacturer%></td> - <td class="cbi-value-field"><%=v.SsdpModelName%></td> - <td class="cbi-value-field"><%=v.DhcpVendor1%></td> - <td class="cbi-value-field"><%=v.DhcpHostname%></td> - </tr> + <div class="tr cbi-section-table-row cbi-rowstyle-<%=(style and 1 or 2)%>"> + <div class="td cbi-value-field"><%=v.Hostname%></div> + <div class="td cbi-value-field"><%=v.Ipv4Address%></div> + <div class="td cbi-value-field"><a href="/cgi-bin/clientdetails?mac=<%=v.MacAddress%>"><%=v.MacAddress%></a></div> + <div class="td cbi-value-field"><%=v.SsdpManufacturer%></div> + <div class="td cbi-value-field"><%=v.SsdpModelName%></div> + <div class="td cbi-value-field"><%=v.DhcpVendor1%></div> + <div class="td cbi-value-field"><%=v.DhcpHostname%></div> + </div> <% style=false end end %> - </table> + </div> </div> </fieldset> diff --git a/applications/luci-app-ocserv/luasrc/view/ocserv_status.htm b/applications/luci-app-ocserv/luasrc/view/ocserv_status.htm index 03a9ed70ee..66e44e9676 100644 --- a/applications/luci-app-ocserv/luasrc/view/ocserv_status.htm +++ b/applications/luci-app-ocserv/luasrc/view/ocserv_status.htm @@ -5,8 +5,8 @@ function(x) { var tb = document.getElementById('ocserv_status_table'); - if (tb && (idx < tb.rows.length)) - tb.rows[0].parentNode.removeChild(tb.rows[idx]); + if (tb && (idx + 1 < tb.childNodes.length)) + tb.removeChild(tb.childNodes[idx + 1]); } ); } @@ -18,38 +18,28 @@ if (st && tb) { /* clear all rows */ - while( tb.rows.length > 1 ) - tb.deleteRow(1); + while (tb.firstElementChild !== tb.lastElementChild) + tb.removeChild(tb.lastElementChild); - for( var i = 0; i < st.length; i++ ) + for (var i = 0; i < st.length; i++) { - var tr = tb.insertRow(-1); - tr.className = 'cbi-section-table-row cbi-rowstyle-' + ((i % 2) + 1); - - tr.insertCell(-1).innerHTML = st[i].user; - tr.insertCell(-1).innerHTML = st[i].group; - tr.insertCell(-1).innerHTML = st[i].vpn_ip; - tr.insertCell(-1).innerHTML = st[i].ip; - tr.insertCell(-1).innerHTML = st[i].device; - tr.insertCell(-1).innerHTML = st[i].time; - tr.insertCell(-1).innerHTML = st[i].cipher; - tr.insertCell(-1).innerHTML = st[i].status; - - tr.insertCell(-1).innerHTML = String.format( - '<input class="cbi-button cbi-input-remove" type="button" value="<%:Disconnect%>" onclick="ocserv_disconnect(%d)" />', - st[i].id - ); + tb.appendChild(E('<div class="tr cbi-section-table-row cbi-rowstyle-%d">'.format((i % 2) + 1), [ + E('<div class="td">', st[i].user), + E('<div class="td">', st[i].group), + E('<div class="td">', st[i].vpn_ip), + E('<div class="td">', st[i].ip), + E('<div class="td">', st[i].device), + E('<div class="td">', st[i].time), + E('<div class="td">', st[i].cipher), + E('<div class="td">', st[i].status), + E('<div class="td">', + E('<input class="cbi-button cbi-input-remove" type="button" value="<%:Disconnect%>" onclick="ocserv_disconnect(%d)" />' + .format(st[i].id))) + ])); } - if( tb.rows.length == 1 ) - { - var tr = tb.insertRow(-1); - tr.className = 'cbi-section-table-row'; - - var td = tr.insertCell(-1); - td.colSpan = 5; - td.innerHTML = '<em><br /><%:There are no active users.%></em>'; - } + if (tb.firstElementChild === tb.lastElementChild) + tb.appendChild(E('<div class="tr cbi-section-table-row"><div class="td"><em><br /><%:There are no active users.%></em></div></div>')); } } ); @@ -57,20 +47,21 @@ <fieldset class="cbi-section"> <legend><%:Active OpenConnect Users%></legend> - <table class="cbi-section-table" id="ocserv_status_table"> - <tr class="cbi-section-table-titles"> - <th class="cbi-section-table-cell"><%:User%></th> - <th class="cbi-section-table-cell"><%:Group%></th> - <th class="cbi-section-table-cell"><%:IP Address%></th> - <th class="cbi-section-table-cell"><%:VPN IP Address%></th> - <th class="cbi-section-table-cell"><%:Device%></th> - <th class="cbi-section-table-cell"><%:Time%></th> - <th class="cbi-section-table-cell"><%:Cipher%></th> - <th class="cbi-section-table-cell"><%:Status%></th> - <th class="cbi-section-table-cell"> </th> - </tr> - <tr class="cbi-section-table-row"> - <td colspan="5"><em><br /><%:Collecting data...%></em></td> - </tr> - </table> + <div class="table cbi-section-table" id="ocserv_status_table"> + <div class="tr cbi-section-table-titles"> + <div class="th cbi-section-table-cell"><%:User%></div> + <div class="th cbi-section-table-cell"><%:Group%></div> + <div class="th cbi-section-table-cell"><%:IP Address%></div> + <div class="th cbi-section-table-cell"><%:VPN IP Address%></div> + <div class="th cbi-section-table-cell"><%:Device%></div> + <div class="th cbi-section-table-cell"><%:Time%></div> + <div class="th cbi-section-table-cell"><%:Cipher%></div> + <div class="th cbi-section-table-cell"><%:Status%></div> + <div class="th cbi-section-table-cell"> </div> + </div> + <div class="tr cbi-section-table-row"> + <div class="td" colspan="5"><em><br /><%:Collecting data...%></em></div> + </div> + </div> </fieldset> + diff --git a/applications/luci-app-olsr-services/luasrc/view/freifunk-services/services.htm b/applications/luci-app-olsr-services/luasrc/view/freifunk-services/services.htm index 476150dd28..150ed87dad 100644 --- a/applications/luci-app-olsr-services/luasrc/view/freifunk-services/services.htm +++ b/applications/luci-app-olsr-services/luasrc/view/freifunk-services/services.htm @@ -132,11 +132,11 @@ end { var service = info[idx]; s += String.format( - '<tr class="cbi-section-table-row cbi-rowstyle-'+(1 + (idx % 2))+'">' + - '<td class="cbi-section-table-titles"><a href="%s">%s</a></td>' + - '<td class="cbi-section-table-titles">%s</td>' + - '<td class="cbi-section-table-titles"><a href="http://%s/cgi-bin-status.html">%s</a></td>' + - '</tr>', + '<div class="tr cbi-section-table-row cbi-rowstyle-'+(1 + (idx % 2))+'">' + + '<div class="td cbi-section-table-titles"><a href="%s">%s</a></div>' + + '<div class="td cbi-section-table-titles">%s</div>' + + '<div class="td cbi-section-table-titles"><a href="http://%s/cgi-bin-status.html">%s</a></div>' + + '</div>', service.url, service.descr, service.proto, service.origin_link, service.origin || '?' ); } @@ -153,16 +153,16 @@ end <fieldset class="cbi-section"> <legend><%:Internal services%></legend> - <table class="cbi-section-table"> - <thead> - <tr class="cbi-section-table-titles"> - <th class="cbi-section-table-cell"><%:Url%></th> - <th class="cbi-section-table-cell"><%:Protocol%></th> - <th class="cbi-section-table-cell"><%:Source%></th> - </tr> - </thead> - - <tbody id="olsr_services"> + <div class="table cbi-section-table"> + <div class="thead"> + <div class="tr cbi-section-table-titles"> + <div class="th cbi-section-table-cell"><%:Url%></div> + <div class="th cbi-section-table-cell"><%:Protocol%></div> + <div class="th cbi-section-table-cell"><%:Source%></div> + </div> + </div> + + <div class="tbody" id="olsr_services"> <% for k, line in ipairs(services) do local field = {} @@ -178,15 +178,15 @@ end local url, proto, descr, origin = pcdata(field[1]), pcdata(field[2]), utl.trim(pcdata(field[3])), pcdata(field[4]) %> - <tr class="cbi-section-table-row cbi-rowstyle-<%=i%>"> - <td class="cbi-section-table-titles"><a href="<%=url%>"><%=descr%></a></td> - <td class="cbi-section-table-titles"><%=proto%></td> - <td class="cbi-section-table-titles"><a href="http://<%=origin_link%>/cgi-bin-status.html"><%=origin%></a></td> - </tr> + <div class="tr cbi-section-table-row cbi-rowstyle-<%=i%>"> + <div class="td cbi-section-table-titles"><a href="<%=url%>"><%=descr%></a></div> + <div class="td cbi-section-table-titles"><%=proto%></div> + <div class="td cbi-section-table-titles"><a href="http://<%=origin_link%>/cgi-bin-status.html"><%=origin%></a></div> + </div> <% i = ((i % 2) + 1) end %> - </tbody> - </table> + </div> + </div> <br /> <%=last_update%> </fieldset> diff --git a/applications/luci-app-olsr/luasrc/view/status-olsr/hna.htm b/applications/luci-app-olsr/luasrc/view/status-olsr/hna.htm index 5ea7b74e4d..2dc4ce1730 100644 --- a/applications/luci-app-olsr/luasrc/view/status-olsr/hna.htm +++ b/applications/luci-app-olsr/luasrc/view/status-olsr/hna.htm @@ -41,7 +41,7 @@ XHR.poll(10, '<%=REQUEST_URI%>', { status: 1 }, { var hna = info[idx]; var linkgw = '' - s += '<tr class="cbi-section-table-row cbi-rowstyle-'+(1 + (idx % 2))+' proto-' + hna.proto + '">' + s += '<div class="tr cbi-section-table-row cbi-rowstyle-'+(1 + (idx % 2))+' proto-' + hna.proto + '">' if (hna.proto == '6') { linkgw = '<a href="http://[' + hna.gateway + ']/cgi-bin-status.html">' + hna.gateway + '</a>' } else { @@ -61,11 +61,11 @@ XHR.poll(10, '<%=REQUEST_URI%>', { status: 1 }, } s += String.format( - '<td class="cbi-section-table-cell">%s</td>' + - '<td class="cbi-section-table-cell">%s</td>' + - '<td class="cbi-section-table-cell">%s</td>', hna.destination + '/' + hna.genmask, linkgw + hostname, validity + '<div class="td cbi-section-table-cell">%s</div>' + + '<div class="td cbi-section-table-cell">%s</div>' + + '<div class="td cbi-section-table-cell">%s</div>', hna.destination + '/' + hna.genmask, linkgw + hostname, validity ) - s += '</tr>' + s += '</div>' } hnadiv.innerHTML = s; } @@ -79,21 +79,21 @@ XHR.poll(10, '<%=REQUEST_URI%>', { status: 1 }, <fieldset class="cbi-section"> <legend><%:Overview of currently active OLSR host net announcements%></legend> - <table class="cbi-section-table"> - <thead> - <tr class="cbi-section-table-titles"> - <th class="cbi-section-table-cell"><%:Announced network%></th> - <th class="cbi-section-table-cell"><%:OLSR gateway%></th> - <th class="cbi-section-table-cell"><%:Validity Time%></th> - </tr> + <div class="table cbi-section-table"> + <div class="thead"> + <div class="tr cbi-section-table-titles"> + <div class="th cbi-section-table-cell"><%:Announced network%></div> + <div class="th cbi-section-table-cell"><%:OLSR gateway%></div> + <div class="th cbi-section-table-cell"><%:Validity Time%></div> + </div> - </thead> - <tbody id="olsrd_hna"> + </div> + <div class="tbody" id="olsrd_hna"> <% for k, route in ipairs(hna) do %> - <tr class="cbi-section-table-row cbi-rowstyle-<%=i%> proto-<%=hna[k].proto%>"> - <td class="cbi-section-table-cell"><%=hna[k].destination%>/<%=hna[k].genmask%> </td> - <td class="cbi-section-table-cell"> + <div class="tr cbi-section-table-row cbi-rowstyle-<%=i%> proto-<%=hna[k].proto%>"> + <div class="td cbi-section-table-cell"><%=hna[k].destination%>/<%=hna[k].genmask%> </div> + <div class="td cbi-section-table-cell"> <% if hna[k].proto == '6' then %> <a href="http://[<%=hna[k].gateway%>]/cgi-bin-status.html"><%=hna[k].gateway%></a> <% else %> @@ -102,20 +102,20 @@ XHR.poll(10, '<%=REQUEST_URI%>', { status: 1 }, <% if hna[k].hostname then %> / <a href="http://<%=hna[k].hostname%>/cgi-bin-status.html"><%=hna[k].hostname%></a> <% end %> - </td> + </div> <% if hna[k].validityTime then validity = hna[k].validityTime .. 's' else validity = '-' end %> - <td class="cbi-section-table-cell"><%=validity%></td> - </tr> + <div class="td cbi-section-table-cell"><%=validity%></div> + </div> <% i = ((i % 2) + 1) end %> - </tbody> - </table> + </div> + </div> </fieldset> <%+status-olsr/common_js%> diff --git a/applications/luci-app-olsr/luasrc/view/status-olsr/interfaces.htm b/applications/luci-app-olsr/luasrc/view/status-olsr/interfaces.htm index 81d0a3dd31..e3ccd0c23d 100644 --- a/applications/luci-app-olsr/luasrc/view/status-olsr/interfaces.htm +++ b/applications/luci-app-olsr/luasrc/view/status-olsr/interfaces.htm @@ -18,31 +18,31 @@ local i = 1 <fieldset class="cbi-section"> <legend><%:Overview of interfaces where OLSR is running%></legend> - <table class="cbi-section-table"> - <tr> - <th class="cbi-section-table-cell"><%:Interface%></th> - <th class="cbi-section-table-cell"><%:State%></th> - <th class="cbi-section-table-cell"><%:MTU%></th> - <th class="cbi-section-table-cell"><%:WLAN%></th> - <th class="cbi-section-table-cell"><%:Source address%></th> - <th class="cbi-section-table-cell"><%:Netmask%></th> - <th class="cbi-section-table-cell"><%:Broadcast address%></th> - </tr> + <div class="table cbi-section-table"> + <div class="tr"> + <div class="th cbi-section-table-cell"><%:Interface%></div> + <div class="th cbi-section-table-cell"><%:State%></div> + <div class="th cbi-section-table-cell"><%:MTU%></div> + <div class="th cbi-section-table-cell"><%:WLAN%></div> + <div class="th cbi-section-table-cell"><%:Source address%></div> + <div class="th cbi-section-table-cell"><%:Netmask%></div> + <div class="th cbi-section-table-cell"><%:Broadcast address%></div> + </div> <% for k, iface in ipairs(iface) do %> - <tr class="cbi-section-table-row cbi-rowstyle-<%=i%> proto-<%=iface.proto%>"> - <td class="cbi-section-table-cell"><%=iface.name%></td> - <td class="cbi-section-table-cell"><%=iface.state%></td> - <td class="cbi-section-table-cell"><%=iface.olsrMTU%></td> - <td class="cbi-section-table-cell"><%=iface.wireless and luci.i18n.translate('yes') or luci.i18n.translate('no')%></td> - <td class="cbi-section-table-cell"><%=iface.ipv4Address or iface.ipv6Address%></td> - <td class="cbi-section-table-cell"><%=iface.netmask%></td> - <td class="cbi-section-table-cell"><%=iface.broadcast or iface.multicast%></td> - </tr> + <div class="tr cbi-section-table-row cbi-rowstyle-<%=i%> proto-<%=iface.proto%>"> + <div class="td cbi-section-table-cell"><%=iface.name%></div> + <div class="td cbi-section-table-cell"><%=iface.state%></div> + <div class="td cbi-section-table-cell"><%=iface.olsrMTU%></div> + <div class="td cbi-section-table-cell"><%=iface.wireless and luci.i18n.translate('yes') or luci.i18n.translate('no')%></div> + <div class="td cbi-section-table-cell"><%=iface.ipv4Address or iface.ipv6Address%></div> + <div class="td cbi-section-table-cell"><%=iface.netmask%></div> + <div class="td cbi-section-table-cell"><%=iface.broadcast or iface.multicast%></div> + </div> <% i = ((i % 2) + 1) end %> - </table> + </div> </fieldset> <%+status-olsr/common_js%> <%+footer%> diff --git a/applications/luci-app-olsr/luasrc/view/status-olsr/mid.htm b/applications/luci-app-olsr/luasrc/view/status-olsr/mid.htm index f658288fc1..8c9f63af0b 100644 --- a/applications/luci-app-olsr/luasrc/view/status-olsr/mid.htm +++ b/applications/luci-app-olsr/luasrc/view/status-olsr/mid.htm @@ -15,11 +15,11 @@ local i = 1 <div id="togglebuttons"></div> <fieldset class="cbi-section"> <legend><%:Overview of known multiple interface announcements%></legend> - <table class="cbi-section-table"> - <tr class="cbi-section-table-titles"> - <th class="cbi-section-table-cell"><%:OLSR node%></th> - <th class="cbi-section-table-cell" ><%:Secondary OLSR interfaces%></th> - </tr> + <div class="table cbi-section-table"> + <div class="tr cbi-section-table-titles"> + <div class="th cbi-section-table-cell"><%:OLSR node%></div> + <div class="th cbi-section-table-cell" ><%:Secondary OLSR interfaces%></div> + </div> <% for k, mid in ipairs(mids) do local aliases = '' @@ -37,14 +37,14 @@ local i = 1 end %> - <tr class="cbi-section-table-row cbi-rowstyle-<%=i%> proto-<%=mid.proto%>"> - <td class="cbi-section-table-cell"><a href="http://<%=host%>/cgi-bin-status.html"><%=mid.ipAddress%></a></td> - <td class="cbi-section-table-cell"><%=aliases%></td> - </tr> + <div class="tr cbi-section-table-row cbi-rowstyle-<%=i%> proto-<%=mid.proto%>"> + <div class="td cbi-section-table-cell"><a href="http://<%=host%>/cgi-bin-status.html"><%=mid.ipAddress%></a></div> + <div class="td cbi-section-table-cell"><%=aliases%></div> + </div> <% i = ((i % 2) + 1) end %> - </table> + </div> </fieldset> <%+status-olsr/common_js%> <%+footer%> diff --git a/applications/luci-app-olsr/luasrc/view/status-olsr/neighbors.htm b/applications/luci-app-olsr/luasrc/view/status-olsr/neighbors.htm index c077c20486..ab09865865 100644 --- a/applications/luci-app-olsr/luasrc/view/status-olsr/neighbors.htm +++ b/applications/luci-app-olsr/luasrc/view/status-olsr/neighbors.htm @@ -64,36 +64,36 @@ end if (neigh.proto == '6') { s += String.format( - '<tr class="cbi-section-table-row cbi-rowstyle-'+(1 + (idx % 2))+' proto-%s">' + - '<td class="cbi-section-table-titles" style="background-color:%s"><a href="http://[%s]/cgi-bin-status.html">%s</a></td>', + '<div class="tr cbi-section-table-row cbi-rowstyle-'+(1 + (idx % 2))+' proto-%s">' + + '<div class="td cbi-section-table-titles" style="background-color:%s"><a href="http://[%s]/cgi-bin-status.html">%s</a></div>', neigh.proto, neigh.dfgcolor, neigh.rip, neigh.rip ); } else { s += String.format( - '<tr class="cbi-section-table-row cbi-rowstyle-'+(1 + (idx % 2))+' proto-%s">' + - '<td class="cbi-section-table-titles" style="background-color:%s"><a href="http://%s/cgi-bin-status.html">%s</a></td>', + '<div class="tr cbi-section-table-row cbi-rowstyle-'+(1 + (idx % 2))+' proto-%s">' + + '<div class="td cbi-section-table-titles" style="background-color:%s"><a href="http://%s/cgi-bin-status.html">%s</a></div>', neigh.proto, neigh.dfgcolor, neigh.rip, neigh.rip ); } if (neigh.hn) { s += String.format( - '<td class="cbi-section-table-titles" style="background-color:%s"><a href="http://%s/cgi-bin-status.html">%s</a></td>', + '<div class="td cbi-section-table-titles" style="background-color:%s"><a href="http://%s/cgi-bin-status.html">%s</a></div>', neigh.dfgcolor, neigh.hn, neigh.hn ); } else { s += String.format( - '<td class="cbi-section-table-titles" style="background-color:%s">?</td>', + '<div class="td cbi-section-table-titles" style="background-color:%s">?</div>', neigh.dfgcolor ); } s += String.format( - '<td class="cbi-section-table-titles" style="background-color:%s">%s</td>' + - '<td class="cbi-section-table-titles" style="background-color:%s">%s</td>' + - '<td class="cbi-section-table-titles" style="background-color:%s">%s</td>' + - '<td class="cbi-section-table-titles" style="background-color:%s">%s</td>' + - '<td class="cbi-section-table-titles" style="background-color:%s">%s</td>' + - '<td class="cbi-section-table-titles" style="background-color:%s" title="Signal: %s Noise: %s">%s</td>' + - '</tr>', + '<div class="td cbi-section-table-titles" style="background-color:%s">%s</div>' + + '<div class="td cbi-section-table-titles" style="background-color:%s">%s</div>' + + '<div class="td cbi-section-table-titles" style="background-color:%s">%s</div>' + + '<div class="td cbi-section-table-titles" style="background-color:%s">%s</div>' + + '<div class="td cbi-section-table-titles" style="background-color:%s">%s</div>' + + '<div class="td cbi-section-table-titles" style="background-color:%s" title="Signal: %s Noise: %s">%s</div>' + + '</div>', neigh.dfgcolor, neigh.ifn, neigh.dfgcolor, neigh.lip, neigh.dfgcolor, neigh.lq, neigh.dfgcolor, neigh.nlq, neigh.color, neigh.cost, neigh.snr_color, neigh.signal, neigh.noise, neigh.snr || '?' ); } @@ -112,21 +112,21 @@ end <fieldset class="cbi-section"> <legend><%:Overview of currently established OLSR connections%></legend> - <table class="cbi-section-table"> - <thead> - <tr class="cbi-section-table-titles"> - <th class="cbi-section-table-cell"><%:Neighbour IP%></th> - <th class="cbi-section-table-cell"><%:Hostname%></th> - <th class="cbi-section-table-cell"><%:Interface%></th> - <th class="cbi-section-table-cell"><%:Local interface IP%></th> - <th class="cbi-section-table-cell">LQ</th> - <th class="cbi-section-table-cell">NLQ</th> - <th class="cbi-section-table-cell">ETX</th> - <th class="cbi-section-table-cell">SNR</th> - </tr> - </thead> + <div class="table cbi-section-table"> + <div class="thead"> + <div class="tr cbi-section-table-titles"> + <div class="th cbi-section-table-cell"><%:Neighbour IP%></div> + <div class="th cbi-section-table-cell"><%:Hostname%></div> + <div class="th cbi-section-table-cell"><%:Interface%></div> + <div class="th cbi-section-table-cell"><%:Local interface IP%></div> + <div class="th cbi-section-table-cell">LQ</div> + <div class="th cbi-section-table-cell">NLQ</div> + <div class="th cbi-section-table-cell">ETX</div> + <div class="th cbi-section-table-cell">SNR</div> + </div> + </div> - <tbody id="olsr_neigh_table"> + <div class="tbody" id="olsr_neigh_table"> <% local i = 1 for k, link in ipairs(links) do link.linkCost = tonumber(link.linkCost) or 0 @@ -147,25 +147,25 @@ end end %> - <tr class="cbi-section-table-row cbi-rowstyle-<%=i%> proto-<%=link.proto%>"> + <div class="tr cbi-section-table-row cbi-rowstyle-<%=i%> proto-<%=link.proto%>"> <% if link.proto == "6" then %> - <td class="cbi-section-table-titles" style="background-color:<%=defaultgw_color%>"><a href="http://[<%=link.remoteIP%>]/cgi-bin-status.html"><%=link.remoteIP%></a></td> + <div class="td cbi-section-table-titles" style="background-color:<%=defaultgw_color%>"><a href="http://[<%=link.remoteIP%>]/cgi-bin-status.html"><%=link.remoteIP%></a></div> <% else %> - <td class="cbi-section-table-titles" style="background-color:<%=defaultgw_color%>"><a href="http://<%=link.remoteIP%>/cgi-bin-status.html"><%=link.remoteIP%></a></td> + <div class="td cbi-section-table-titles" style="background-color:<%=defaultgw_color%>"><a href="http://<%=link.remoteIP%>/cgi-bin-status.html"><%=link.remoteIP%></a></div> <% end %> - <td class="cbi-section-table-titles" style="background-color:<%=defaultgw_color%>"><a href="http://<%=link.hostname%>/cgi-bin-status.html"><%=link.hostname%></a></td> - <td class="cbi-section-table-titles" style="background-color:<%=defaultgw_color%>"><%=link.interface%></td> - <td class="cbi-section-table-titles" style="background-color:<%=defaultgw_color%>"><%=link.localIP%></td> - <td class="cbi-section-table-titles" style="background-color:<%=defaultgw_color%>"><%=string.format("%.3f", link.linkQuality)%></td> - <td class="cbi-section-table-titles" style="background-color:<%=defaultgw_color%>"><%=string.format("%.3f", link.neighborLinkQuality)%></td> - <td class="cbi-section-table-titles" style="background-color:<%=color%>"><%=string.format("%.3f", link.linkCost)%></td> - <td class="cbi-section-table-titles" style="background-color:<%=snr_color%>" title="Signal: <%=link.signal%> Noise: <%=link.noise%>"><%=link.snr%></td> - </tr> + <div class="td cbi-section-table-titles" style="background-color:<%=defaultgw_color%>"><a href="http://<%=link.hostname%>/cgi-bin-status.html"><%=link.hostname%></a></div> + <div class="td cbi-section-table-titles" style="background-color:<%=defaultgw_color%>"><%=link.interface%></div> + <div class="td cbi-section-table-titles" style="background-color:<%=defaultgw_color%>"><%=link.localIP%></div> + <div class="td cbi-section-table-titles" style="background-color:<%=defaultgw_color%>"><%=string.format("%.3f", link.linkQuality)%></div> + <div class="td cbi-section-table-titles" style="background-color:<%=defaultgw_color%>"><%=string.format("%.3f", link.neighborLinkQuality)%></div> + <div class="td cbi-section-table-titles" style="background-color:<%=color%>"><%=string.format("%.3f", link.linkCost)%></div> + <div class="td cbi-section-table-titles" style="background-color:<%=snr_color%>" title="Signal: <%=link.signal%> Noise: <%=link.noise%>"><%=link.snr%></div> + </div> <% i = ((i % 2) + 1) end %> - </tbody> - </table> + </div> + </div> <br /> <%+status-olsr/legend%> diff --git a/applications/luci-app-olsr/luasrc/view/status-olsr/overview.htm b/applications/luci-app-olsr/luasrc/view/status-olsr/overview.htm index 61e17b3b2d..832a27aed7 100644 --- a/applications/luci-app-olsr/luasrc/view/status-olsr/overview.htm +++ b/applications/luci-app-olsr/luasrc/view/status-olsr/overview.htm @@ -160,48 +160,48 @@ XHR.poll(10, '<%=REQUEST_URI%>/json', { }, <fieldset class="cbi-section"> <legend><%:Network%></legend> - <table width="100%" cellspacing="10"> - <tr><td width="33%"><%:Interfaces%></td><td> + <div class="table" width="100%" cellspacing="10"> + <div class="tr"><div class="td" width="33%"><%:Interfaces%></div><div class="td"> <a href="<%=REQUEST_URI%>/interfaces"> <span id="nr_ifaces">-<span> </a> - </td></tr> - <tr><td width="33%"><%:Neighbors%></td><td> + </div></div> + <div class="tr"><div class="td" width="33%"><%:Neighbors%></div><div class="td"> <a href="<%=REQUEST_URI%>/neighbors"> <span id="nr_neigh">-</span> </a> - </td></tr> - <tr><td width="33%"><%:Nodes%></td><td> + </div></div> + <div class="tr"><div class="td" width="33%"><%:Nodes%></div><div class="td"> <a href="<%=REQUEST_URI%>/topology"> <span id="nr_nodes">-</span> </a> - </td></tr> - <tr><td width="33%"><%:HNA%></td><td> + </div></div> + <div class="tr"><div class="td" width="33%"><%:HNA%></div><div class="td"> <a href="<%=REQUEST_URI%>/hna"> <span id="nr_hna">-</span> </a> - </td></tr> - <tr><td width="33%"><%:Links total%></td><td> + </div></div> + <div class="tr"><div class="td" width="33%"><%:Links total%></div><div class="td"> <a href="<%=REQUEST_URI%>/topology"> <span id="nr_topo">-</span> </a> - </td></tr> - <tr><td width="33%"><%:Links per node (average)%></td><td> + </div></div> + <div class="tr"><div class="td" width="33%"><%:Links per node (average)%></div><div class="td"> <span id="meshfactor">-</span> - </td></tr> + </div></div> - </table> + </div> </fieldset> <fieldset class="cbi-section"> <legend>OLSR <%:Configuration%></legend> - <table width="100%" cellspacing="10"> - <tr><td width="33%"><%:Version%></td><td> + <div class="table" width="100%" cellspacing="10"> + <div class="tr"><div class="td" width="33%"><%:Version%></div><div class="td"> <span id="version">-<span> - </td></tr> - <tr><td width="33%"><%:Download Config%></td><td> + </div></div> + <div class="tr"><div class="td" width="33%"><%:Download Config%></div><div class="td"> <% if has_ipv4_conf then %> <a href="<%=REQUEST_URI%>?openwrt_v4">OpenWrt (IPv4)</a>, <% end %> @@ -214,8 +214,8 @@ XHR.poll(10, '<%=REQUEST_URI%>/json', { }, <% if has_ipv6_conf then %> <a href="<%=REQUEST_URI%>?conf_v6">OLSRD (IPv6)</a> <% end %> - </td></tr> - </table> + </div></div> + </div> </fieldset> <%+footer%> diff --git a/applications/luci-app-olsr/luasrc/view/status-olsr/routes.htm b/applications/luci-app-olsr/luasrc/view/status-olsr/routes.htm index 8e46daa022..c75b94fcef 100644 --- a/applications/luci-app-olsr/luasrc/view/status-olsr/routes.htm +++ b/applications/luci-app-olsr/luasrc/view/status-olsr/routes.htm @@ -50,9 +50,9 @@ XHR.poll(20, '<%=REQUEST_URI%>', { status: 1 }, var route = info[idx]; s += String.format( - '<tr class="cbi-section-table-row cbi-rowstyle-'+(1 + (idx % 2))+' proto-%s">' + - '<td class="cbi-section-table-cell">%s/%s</td>' + - '<td class="cbi-section-table-cell">' + + '<div class="tr cbi-section-table-row cbi-rowstyle-'+(1 + (idx % 2))+' proto-%s">' + + '<div class="td cbi-section-table-cell">%s/%s</div>' + + '<div class="td cbi-section-table-cell">' + '<a href="http://%s/cgi-bin-status.html">%s</a>', route.proto, route.dest, route.genmask, route.gw, route.gw ) @@ -72,11 +72,11 @@ XHR.poll(20, '<%=REQUEST_URI%>', { status: 1 }, } s += String.format( - '</td>' + - '<td class="cbi-section-table-cell">%s</td>' + - '<td class="cbi-section-table-cell">%s</td>' + - '<td class="cbi-section-table-cell" style="background-color:%s">%s</td>' + - '</tr>', + '</div>' + + '<div class="td cbi-section-table-cell">%s</div>' + + '<div class="td cbi-section-table-cell">%s</div>' + + '<div class="td cbi-section-table-cell" style="background-color:%s">%s</div>' + + '</div>', route.interface, route.metric, route.color, route.etx || '?' ); } @@ -96,27 +96,27 @@ XHR.poll(20, '<%=REQUEST_URI%>', { status: 1 }, <fieldset class="cbi-section"> <legend><%:Overview of currently known routes to other OLSR nodes%></legend> -<table class="cbi-section-table"> - <thead> - <tr class="cbi-section-table-titles"> - <th class="cbi-section-table-cell"><%:Announced network%></th> - <th class="cbi-section-table-cell"><%:OLSR gateway%></th> - <th class="cbi-section-table-cell"><%:Interface%></th> - <th class="cbi-section-table-cell"><%:Metric%></th> - <th class="cbi-section-table-cell">ETX</th> - </tr> - </thead> +<div class="table cbi-section-table"> + <div class="thead"> + <div class="tr cbi-section-table-titles"> + <div class="th cbi-section-table-cell"><%:Announced network%></div> + <div class="th cbi-section-table-cell"><%:OLSR gateway%></div> + <div class="th cbi-section-table-cell"><%:Interface%></div> + <div class="th cbi-section-table-cell"><%:Metric%></div> + <div class="th cbi-section-table-cell">ETX</div> + </div> + </div> - <tbody id="olsrd_routes"> + <div class="tbody" id="olsrd_routes"> <% for k, route in ipairs(routes) do ETX = tonumber(route.rtpMetricCost)/1024 or '0' color = olsrtools.etx_color(ETX) %> - <tr class="cbi-section-table-row cbi-rowstyle-<%=i%> proto-<%=route.proto%>"> - <td class="cbi-section-table-cell"><%=route.destination%>/<%=route.genmask%></td> - <td class="cbi-section-table-cell"> + <div class="tr cbi-section-table-row cbi-rowstyle-<%=i%> proto-<%=route.proto%>"> + <div class="td cbi-section-table-cell"><%=route.destination%>/<%=route.genmask%></div> + <div class="td cbi-section-table-cell"> <% if route.proto == '6' then %> <a href="http://[<%=route.gateway%>]/cgi-bin-status.html"><%=route.gateway%></a> <% else %> @@ -125,16 +125,16 @@ XHR.poll(20, '<%=REQUEST_URI%>', { status: 1 }, <% if route.hostname then %> / <a href="http://<%=route.Hostname%>/cgi-bin-status.html"><%=route.hostname%></a> <% end %> - </td> - <td class="cbi-section-table-cell"><%=route.networkInterface%></td> - <td class="cbi-section-table-cell"><%=route.metric%></td> - <td class="cbi-section-table-cell" style="background-color:<%=color%>"><%=string.format("%.3f", ETX)%></td> - </tr> + </div> + <div class="td cbi-section-table-cell"><%=route.networkInterface%></div> + <div class="td cbi-section-table-cell"><%=route.metric%></div> + <div class="td cbi-section-table-cell" style="background-color:<%=color%>"><%=string.format("%.3f", ETX)%></div> + </div> <% i = ((i % 2) + 1) end %> - </tbody> -</table> + </div> +</div> <%+status-olsr/legend%> </fieldset> diff --git a/applications/luci-app-olsr/luasrc/view/status-olsr/smartgw.htm b/applications/luci-app-olsr/luasrc/view/status-olsr/smartgw.htm index 6aa7a75461..7ca66816ae 100644 --- a/applications/luci-app-olsr/luasrc/view/status-olsr/smartgw.htm +++ b/applications/luci-app-olsr/luasrc/view/status-olsr/smartgw.htm @@ -56,7 +56,7 @@ XHR.poll(10, '<%=REQUEST_URI%>', { status: 1 }, for (var idx = 0; idx < info.length; idx++) { var smartgw = info[idx]; - s += '<tr class="cbi-section-table-row cbi-rowstyle-'+(1 + (idx % 2))+' proto-' + smartgw.proto + '">' + s += '<div class="tr cbi-section-table-row cbi-rowstyle-'+(1 + (idx % 2))+' proto-' + smartgw.proto + '">' if (smartgw.proto == '6') { linkgw = '<a href="http://[' + smartgw.ipAddress + ']/cgi-bin-status.html">' + smartgw.ipAddress + '</a>' } else { @@ -64,18 +64,18 @@ XHR.poll(10, '<%=REQUEST_URI%>', { status: 1 }, } s += String.format( - '<td class="cbi-section-table-cell">%s</td>' + - '<td class="cbi-section-table-cell">%s</td>' + - '<td class="cbi-section-table-cell">%s</td>' + - '<td class="cbi-section-table-cell">%s</td>' + - '<td class="cbi-section-table-cell">%s</td>' + - '<td class="cbi-section-table-cell">%s</td>' + - '<td class="cbi-section-table-cell">%s</td>' + - '<td class="cbi-section-table-cell">%s</td>' + - '<td class="cbi-section-table-cell">%s</td>', + '<div class="td cbi-section-table-cell">%s</div>' + + '<div class="td cbi-section-table-cell">%s</div>' + + '<div class="td cbi-section-table-cell">%s</div>' + + '<div class="td cbi-section-table-cell">%s</div>' + + '<div class="td cbi-section-table-cell">%s</div>' + + '<div class="td cbi-section-table-cell">%s</div>' + + '<div class="td cbi-section-table-cell">%s</div>' + + '<div class="td cbi-section-table-cell">%s</div>' + + '<div class="td cbi-section-table-cell">%s</div>', linkgw, smartgw.status, smartgw.tcPathCost, smartgw.hopCount, smartgw.uplinkSpeed, smartgw.downlinkSpeed, smartgw.v4, smartgw.v6, smartgw.externalPrefix ) - s += '</tr>' + s += '</div>' } smartgwdiv.innerHTML = s; } @@ -94,23 +94,23 @@ XHR.poll(10, '<%=REQUEST_URI%>', { status: 1 }, <fieldset class="cbi-section"> <legend><%:Overview of smart gateways in this network%></legend> - <table class="cbi-section-table"> - <thead> - <tr class="cbi-section-table-titles"> - <th class="cbi-section-table-cell"><%:Gateway%></th> - <th class="cbi-section-table-cell"><%:Status%></th> - <th class="cbi-section-table-cell"><%:ETX%></th> - <th class="cbi-section-table-cell"><%:Hops%></th> - <th class="cbi-section-table-cell"><%:Uplink%></th> - <th class="cbi-section-table-cell"><%:Downlink%></th> - <th class="cbi-section-table-cell"><%:IPv4%></th> - <th class="cbi-section-table-cell"><%:IPv6%></th> - <th class="cbi-section-table-cell"><%:Prefix%></th> - - </tr> - </thead> - - <tbody id="olsrd_smartgw"> + <div class="table cbi-section-table"> + <div class="thead"> + <div class="tr cbi-section-table-titles"> + <div class="th cbi-section-table-cell"><%:Gateway%></div> + <div class="th cbi-section-table-cell"><%:Status%></div> + <div class="th cbi-section-table-cell"><%:ETX%></div> + <div class="th cbi-section-table-cell"><%:Hops%></div> + <div class="th cbi-section-table-cell"><%:Uplink%></div> + <div class="th cbi-section-table-cell"><%:Downlink%></div> + <div class="th cbi-section-table-cell"><%:IPv4%></div> + <div class="th cbi-section-table-cell"><%:IPv6%></div> + <div class="th cbi-section-table-cell"><%:Prefix%></div> + + </div> + </div> + + <div class="tbody" id="olsrd_smartgw"> <% for k, gw in ipairs(gws) do gw.tcPathCost = tonumber(gw.tcPathCost)/1024 or 0 @@ -119,27 +119,27 @@ XHR.poll(10, '<%=REQUEST_URI%>', { status: 1 }, end %> - <tr class="cbi-section-table-row cbi-rowstyle-<%=i%> proto-<%=proto%>"> + <div class="tr cbi-section-table-row cbi-rowstyle-<%=i%> proto-<%=proto%>"> <% if gw.proto == '6' then %> - <td class="cbi-section-table-cell"><a href="http://[<%=gw.ipAddress%>]/cgi-bin-status.html"><%=gw.ipAddress%></a></td> + <div class="td cbi-section-table-cell"><a href="http://[<%=gw.ipAddress%>]/cgi-bin-status.html"><%=gw.ipAddress%></a></div> <% else %> - <td class="cbi-section-table-cell"><a href="http://<%=gw.ipAddress%>/cgi-bin-status.html"><%=gw.ipAddress%></a></td> + <div class="td cbi-section-table-cell"><a href="http://<%=gw.ipAddress%>/cgi-bin-status.html"><%=gw.ipAddress%></a></div> <% end %> - <td class="cbi-section-table-cell"><%=gw.ipv4Status or gw.ipv6Status or '-' %></td> - <td class="cbi-section-table-cell"><%=string.format("%.3f", gw.tcPathCost)%></td> - <td class="cbi-section-table-cell"><%=gw.hopCount%></td> - <td class="cbi-section-table-cell"><%=gw.uplinkSpeed%></td> - <td class="cbi-section-table-cell"><%=gw.downlinkSpeed%></td> - <td class="cbi-section-table-cell"><%=gw.ipv4 and luci.i18n.translate('yes') or luci.i18n.translate('no')%></td> - <td class="cbi-section-table-cell"><%=gw.ipv6 and luci.i18n.translate('yes') or luci.i18n.translate('no')%></td> - <td class="cbi-section-table-cell"><%=gw.externalPrefix%></td> - </tr> + <div class="td cbi-section-table-cell"><%=gw.ipv4Status or gw.ipv6Status or '-' %></div> + <div class="td cbi-section-table-cell"><%=string.format("%.3f", gw.tcPathCost)%></div> + <div class="td cbi-section-table-cell"><%=gw.hopCount%></div> + <div class="td cbi-section-table-cell"><%=gw.uplinkSpeed%></div> + <div class="td cbi-section-table-cell"><%=gw.downlinkSpeed%></div> + <div class="td cbi-section-table-cell"><%=gw.ipv4 and luci.i18n.translate('yes') or luci.i18n.translate('no')%></div> + <div class="td cbi-section-table-cell"><%=gw.ipv6 and luci.i18n.translate('yes') or luci.i18n.translate('no')%></div> + <div class="td cbi-section-table-cell"><%=gw.externalPrefix%></div> + </div> <% i = ((i % 2) + 1) end %> - </tbody> - </table> + </div> + </div> </fieldset> <% else %> diff --git a/applications/luci-app-olsr/luasrc/view/status-olsr/topology.htm b/applications/luci-app-olsr/luasrc/view/status-olsr/topology.htm index b3abeaecbe..02fdfddac3 100644 --- a/applications/luci-app-olsr/luasrc/view/status-olsr/topology.htm +++ b/applications/luci-app-olsr/luasrc/view/status-olsr/topology.htm @@ -17,14 +17,14 @@ local olsrtools = require "luci.tools.olsr" <fieldset class="cbi-section"> <legend><%:Overview of currently known OLSR nodes%></legend> - <table class="cbi-section-table"> - <tr class="cbi-section-table-titles"> - <th class="cbi-section-table-cell"><%:OLSR node%></th> - <th class="cbi-section-table-cell"><%:Last hop%></th> - <th class="cbi-section-table-cell"><%:LQ%></th> - <th class="cbi-section-table-cell"><%:NLQ%></th> - <th class="cbi-section-table-cell"><%:ETX%></th> - </tr> + <div class="table cbi-section-table"> + <div class="tr cbi-section-table-titles"> + <div class="th cbi-section-table-cell"><%:OLSR node%></div> + <div class="th cbi-section-table-cell"><%:Last hop%></div> + <div class="th cbi-section-table-cell"><%:LQ%></div> + <div class="th cbi-section-table-cell"><%:NLQ%></div> + <div class="th cbi-section-table-cell"><%:ETX%></div> + </div> <% for k, route in ipairs(routes) do local cost = string.format("%.3f", tonumber(route.tcEdgeCost/1024) or 0) @@ -33,28 +33,28 @@ local olsrtools = require "luci.tools.olsr" local nlq = string.format("%.3f", tonumber(route.neighborLinkQuality) or 0) %> - <tr class="cbi-section-table-row cbi-rowstyle-<%=i%> proto-<%=route.proto%>"> + <div class="tr cbi-section-table-row cbi-rowstyle-<%=i%> proto-<%=route.proto%>"> <% if route.proto == "6" then %> - <td class="cbi-section-table-cell"><a href="http://[<%=route.destinationIP%>]/cgi-bin-status.html"><%=route.destinationIP%></a></td> - <td class="cbi-section-table-cell"><a href="http://[<%=route.lastHopIP%>]/cgi-bin-status.html"><%=route.lastHopIP%></a></td> + <div class="td cbi-section-table-cell"><a href="http://[<%=route.destinationIP%>]/cgi-bin-status.html"><%=route.destinationIP%></a></div> + <div class="td cbi-section-table-cell"><a href="http://[<%=route.lastHopIP%>]/cgi-bin-status.html"><%=route.lastHopIP%></a></div> <% else %> - <td class="cbi-section-table-cell"><a href="http://<%=route.destinationIP%>/cgi-bin-status.html"><%=route.destinationIP%></a></td> - <td class="cbi-section-table-cell"><a href="http://<%=route.lastHopIP%>/cgi-bin-status.html"><%=route.lastHopIP%></a></td> + <div class="td cbi-section-table-cell"><a href="http://<%=route.destinationIP%>/cgi-bin-status.html"><%=route.destinationIP%></a></div> + <div class="td cbi-section-table-cell"><a href="http://<%=route.lastHopIP%>/cgi-bin-status.html"><%=route.lastHopIP%></a></div> <%end%> - <td class="cbi-section-table-cell"><%=lq%></td> - <td class="cbi-section-table-cell"><%=nlq%></td> - <td class="cbi-section-table-cell" style="background-color:<%=color%>"><%=cost%></td> - </tr> + <div class="td cbi-section-table-cell"><%=lq%></div> + <div class="td cbi-section-table-cell"><%=nlq%></div> + <div class="td cbi-section-table-cell" style="background-color:<%=color%>"><%=cost%></div> + </div> <% i = ((i % 2) + 1) end %> - </table> + </div> <%+status-olsr/legend%> </fieldset> diff --git a/applications/luci-app-openvpn/luasrc/model/cbi/openvpn.lua b/applications/luci-app-openvpn/luasrc/model/cbi/openvpn.lua index d2b5d32c05..a6b0e1dd90 100644 --- a/applications/luci-app-openvpn/luasrc/model/cbi/openvpn.lua +++ b/applications/luci-app-openvpn/luasrc/model/cbi/openvpn.lua @@ -56,7 +56,7 @@ function s.create(self, name) luci.cbi.CREATE_PREFIX .. self.config .. "." .. self.sectiontype .. ".text" ) - if string.len(name)>3 and not name:match("[^a-zA-Z0-9_]") then + if #name > 3 and not name:match("[^a-zA-Z0-9_]") then uci:section( "openvpn", "openvpn", name, uci:get_all( "openvpn_recipes", recipe ) @@ -67,9 +67,11 @@ function s.create(self, name) uci:save("openvpn") luci.http.redirect( self.extedit:format(name) ) - else + elseif #name > 0 then self.invalid_cts = true end + + return 0 end @@ -103,10 +105,7 @@ function updown.cfgvalue(self, section) end function updown.write(self, section, value) if self.option == "stop" then - local pid = s.getPID(section) - if pid ~= nil then - sys.process.signal(pid,15) - end + luci.sys.call("/etc/init.d/openvpn stop %s" % section) else luci.sys.call("/etc/init.d/openvpn start %s" % section) end @@ -126,5 +125,8 @@ function proto.cfgvalue(self, section) return val or "udp" end +function m.on_after_commit(self,map) + require("luci.sys").call('/etc/init.d/openvpn reload') +end return m diff --git a/applications/luci-app-shadowsocks-libev/luasrc/model/shadowsocks-libev.lua b/applications/luci-app-shadowsocks-libev/luasrc/model/shadowsocks-libev.lua index af1a75b6f2..5fc20c52bc 100644 --- a/applications/luci-app-shadowsocks-libev/luasrc/model/shadowsocks-libev.lua +++ b/applications/luci-app-shadowsocks-libev/luasrc/model/shadowsocks-libev.lua @@ -23,7 +23,7 @@ function values_actions(o) end function values_redir(o, xmode) - o.map.uci.foreach("shadowsocks-libev", "ss_redir", function(sdata) + o.map.uci:foreach("shadowsocks-libev", "ss_redir", function(sdata) local disabled = ucival_to_bool(sdata["disabled"]) local sname = sdata[".name"] local mode = sdata["mode"] or "tcp_only" @@ -37,7 +37,7 @@ function values_redir(o, xmode) end function values_serverlist(o) - o.map.uci.foreach("shadowsocks-libev", "server", function(sdata) + o.map.uci:foreach("shadowsocks-libev", "server", function(sdata) local sname = sdata[".name"] local server = sdata["server"] local server_port = sdata["server_port"] diff --git a/applications/luci-app-shadowsocks-libev/luasrc/view/shadowsocks-libev/add_instance.htm b/applications/luci-app-shadowsocks-libev/luasrc/view/shadowsocks-libev/add_instance.htm index 219d89b074..80b95564dd 100644 --- a/applications/luci-app-shadowsocks-libev/luasrc/view/shadowsocks-libev/add_instance.htm +++ b/applications/luci-app-shadowsocks-libev/luasrc/view/shadowsocks-libev/add_instance.htm @@ -1,8 +1,8 @@ <div class="cbi-section-create cbi-tblsection-create"> <br /> - <table class="cbi-section-table"> - <tr class="cbi-section-table-row"> - <td class="cbi-section-table-cell" style="width:140px"> + <div class="table cbi-section-table"> + <div class="tr cbi-section-table-row"> + <div class="td cbi-section-table-cell" style="width:140px"> <select class="cbi-input-select" id="_newinst.type" name="_newinst.type"> <option value="_dummy">-- instance type --</option> <option value="ss_local">ss-local</option> @@ -10,15 +10,15 @@ <option value="ss_redir">ss-redir</option> <option value="ss_server">ss-server</option> </select> - </td> - <td class="cbi-section-table-cell" style="width:110px"> + </div> + <div class="td cbi-section-table-cell" style="width:110px"> <input type="text" class="cbi-input-text" id="_newinst.name" name="_newinst.name" placeholder="<%:Name%>"/> - </td> - <td class="cbi-section-table-cell left"> + </div> + <div class="td cbi-section-table-cell left"> <input type="submit" class="cbi-button cbi-button-add" name="cbi.cts.<%=self.config%>" value="<%:Add%>" /> - </td> - </tr> - </table> + </div> + </div> + </div> </div> <script type="text/javascript">//<![CDATA[ XHR.poll(5, '<%=url('admin/services/shadowsocks-libev/status')%>', null, diff --git a/applications/luci-app-splash/luasrc/view/admin_status/splash.htm b/applications/luci-app-splash/luasrc/view/admin_status/splash.htm index 37f67776aa..aad330791d 100644 --- a/applications/luci-app-splash/luasrc/view/admin_status/splash.htm +++ b/applications/luci-app-splash/luasrc/view/admin_status/splash.htm @@ -145,19 +145,19 @@ end { var s = ''; if (info.length == undefined) { - s += '<tr class="cbi-section-table-row"><td colspan="7" class="cbi-section-table-cell"><br /><em><%:No clients connected%></em><br /></td></tr>' + s += '<div class="tr cbi-section-table-row"><div colspan="7" class="td cbi-section-table-cell"><br /><em><%:No clients connected%></em><br /></div></div>' }; for (var idx = 0; idx < info.length; idx++) { var splash = info[idx]; s += String.format( - '<tr class="cbi-section-table-row cbi-rowstyle-'+(1 + (idx % 2))+'">' + - '<td class="cbi-section-table-cell">%s</td>' + - '<td class="cbi-section-table-cell">%s</td>' + - '<td class="cbi-section-table-cell">%s</td>' + - '<td class="cbi-section-table-cell">%s</td>' + - '<td class="cbi-section-table-cell">%s/%s</td>' + - '<td class="cbi-section-table-cell">', + '<div class="tr cbi-section-table-row cbi-rowstyle-'+(1 + (idx % 2))+'">' + + '<div class="td cbi-section-table-cell">%s</div>' + + '<div class="td cbi-section-table-cell">%s</div>' + + '<div class="td cbi-section-table-cell">%s</div>' + + '<div class="td cbi-section-table-cell">%s</div>' + + '<div class="td cbi-section-table-cell">%s/%s</div>' + + '<div class="td cbi-section-table-cell">', splash.hostname, splash.ip, splash.mac, splash.timeleft, splash.trafficin, splash.trafficout); <% if is_admin then %> @@ -185,7 +185,7 @@ end <% else %> s += String.format('%s', splash.policy); <% end %> - s += '</td></tr>' + s += '</div></div>' } tbody.innerHTML = s; } @@ -200,18 +200,18 @@ end <legend><%:Active Clients%></legend> <div class="cbi-section-node"> <% if is_admin then %><form action="<%=REQUEST_URI%>" method="post"><input type="hidden" name="token" value="<%=token%>" /><% end %> - <table class="cbi-section-table"> - <thead> - <tr class="cbi-section-table-titles"> - <th class="cbi-section-table-cell"><%:Hostname%></th> - <th class="cbi-section-table-cell"><%:IP Address%></th> - <th class="cbi-section-table-cell"><%:MAC Address%></th> - <th class="cbi-section-table-cell"><%:Time remaining%></th> - <th class="cbi-section-table-cell"><%:Traffic in/out%></th> - <th class="cbi-section-table-cell"><%:Policy%></th> - </tr> - </thead> - <tbody id="splash_table"> + <div class="table cbi-section-table"> + <div class="thead"> + <div class="tr cbi-section-table-titles"> + <div class="th cbi-section-table-cell"><%:Hostname%></div> + <div class="th cbi-section-table-cell"><%:IP Address%></div> + <div class="th cbi-section-table-cell"><%:MAC Address%></div> + <div class="th cbi-section-table-cell"><%:Time remaining%></div> + <div class="th cbi-section-table-cell"><%:Traffic in/out%></div> + <div class="th cbi-section-table-cell"><%:Policy%></div> + </div> + </div> + <div class="tbody" id="splash_table"> <%- local count = 0 @@ -227,16 +227,16 @@ end if c.ip then count = count + 1 -%> - <tr class="cbi-section-table-row cbi-rowstyle-<%=2-(count%2)%>"> - <td class="cbi-section-table-cell"><%=c.hostname or "<em>" .. translate("unknown") .. "</em>"%></td> - <td class="cbi-section-table-cell"><%=c.ip or "<em>" .. translate("unknown") .. "</em>"%></td> - <td class="cbi-section-table-cell"><%=showmac(c.mac)%></td> - <td class="cbi-section-table-cell"><%= + <div class="tr cbi-section-table-row cbi-rowstyle-<%=2-(count%2)%>"> + <div class="td cbi-section-table-cell"><%=c.hostname or "<em>" .. translate("unknown") .. "</em>"%></div> + <div class="td cbi-section-table-cell"><%=c.ip or "<em>" .. translate("unknown") .. "</em>"%></div> + <div class="td cbi-section-table-cell"><%=showmac(c.mac)%></div> + <div class="td cbi-section-table-cell"><%= (c.limit >= os.time()) and wat.date_format(c.limit-os.time()) or (c.policy ~= "normal") and "-" or "<em>" .. translate("expired") .. "</em>" - %></td> - <td class="cbi-section-table-cell"><%=wat.byte_format(c.bytes_in)%> / <%=wat.byte_format(c.bytes_out)%></td> - <td class="cbi-section-table-cell"> + %></div> + <div class="td cbi-section-table-cell"><%=wat.byte_format(c.bytes_in)%> / <%=wat.byte_format(c.bytes_out)%></div> + <div class="td cbi-section-table-cell"> <% if is_admin then %> <select name="policy.<%=c.mac:lower()%>" style="width:200px"> <option value="whitelist"<%=c.policy=="whitelist" and ' selected="selected"'%>><%:whitelisted%></option> @@ -250,21 +250,21 @@ end <% else %> <%=c.policy%> <% end %> - </td> - </tr> + </div> + </div> <%- end end if count == 0 then -%> - <tr class="cbi-section-table-row"> - <td colspan="7" class="cbi-section-table-cell"> + <div class="tr cbi-section-table-row"> + <div colspan="7" class="td cbi-section-table-cell"> <br /><em><%:No clients connected%></em><br /> - </td> - </tr> + </div> + </div> <%- end -%> - </tbody> - </table> + </div> + </div> <% if is_admin then %></form><% end %> </div> </fieldset> diff --git a/applications/luci-app-travelmate/luasrc/view/travelmate/stations.htm b/applications/luci-app-travelmate/luasrc/view/travelmate/stations.htm index f76b52e9cc..bee6fcb360 100644 --- a/applications/luci-app-travelmate/luasrc/view/travelmate/stations.htm +++ b/applications/luci-app-travelmate/luasrc/view/travelmate/stations.htm @@ -17,14 +17,14 @@ This is free software, licensed under the Apache License, Version 2.0 </div> <fieldset class="cbi-section"> - <table class="cbi-section-table" style="empty-cells:hide"> - <tr class="cbi-section-table-titles"> - <th class="cbi-section-table-cell" style="text-align:left"><%:Device%></th> - <th class="cbi-section-table-cell" style="text-align:left"><%:SSID%></th> - <th class="cbi-section-table-cell" style="text-align:left"><%:BSSID%></th> - <th class="cbi-section-table-cell" style="text-align:left"><%:Encryption%></th> - <th class="cbi-section-table-cell" style="text-align:center" colspan="2"><%:Actions%></th> - </tr> + <div class="table cbi-section-table" style="empty-cells:hide"> + <div class="tr cbi-section-table-titles"> + <div class="th cbi-section-table-cell" style="text-align:left"><%:Device%></div> + <div class="th cbi-section-table-cell" style="text-align:left"><%:SSID%></div> + <div class="th cbi-section-table-cell" style="text-align:left"><%:BSSID%></div> + <div class="th cbi-section-table-cell" style="text-align:left"><%:Encryption%></div> + <div class="th cbi-section-table-cell" style="text-align:center" colspan="2"><%:Actions%></div> + </div> <% uci:foreach("wireless", "wifi-iface", function(s) local iface = s.network or "" @@ -40,25 +40,25 @@ This is free software, licensed under the Apache License, Version 2.0 style = "text-align:left;color:#0069d6;font-weight:bold" end %> - <tr class="cbi-section-table-row cbi-rowstyle-1" style="<%=style%>"> - <td style="<%=style%>"><%=device%></td> - <td style="<%=style%>"><%=ssid%></td> - <td style="<%=style%>"><%=bssid%></td> - <td style="<%=style%>"><%=encryption%></td> - <td class="cbi-value-field" style="width:80px"> - <input class="cbi-button cbi-button-up" type="button" value="" onclick="location.href='<%=luci.dispatcher.build_url('admin/services/travelmate/wifiorder')%>?cfg=<%=section%>&dir=up'" alt="<%:Move up%>" title="<%:Move up%>"/> - <input class="cbi-button cbi-button-down" type="button" value="" onclick="location.href='<%=luci.dispatcher.build_url('admin/services/travelmate/wifiorder')%>?cfg=<%=section%>&dir=down'" alt="<%:Move down%>" title="<%:Move down%>"/> - </td> - <td class="cbi-value-field" style="width:150px"> + <div class="tr cbi-section-table-row cbi-rowstyle-1" style="<%=style%>"> + <div class="td" style="<%=style%>"><%=device%></div> + <div class="td" style="<%=style%>"><%=ssid%></div> + <div class="td" style="<%=style%>"><%=bssid%></div> + <div class="td" style="<%=style%>"><%=encryption%></div> + <div class="td cbi-value-field" style="width:80px"> + <input class="cbi-button cbi-button-up" type="button" value="" onclick="location.href='<%=luci.dispatcher.build_url('admin/services/travelmate/wifiorder')%>?cfg=<%=section%>&dir=up'" alt="<%:Move up%>" title="<%:Move up%>"/> + <input class="cbi-button cbi-button-down" type="button" value="" onclick="location.href='<%=luci.dispatcher.build_url('admin/services/travelmate/wifiorder')%>?cfg=<%=section%>&dir=down'" alt="<%:Move down%>" title="<%:Move down%>"/> + </div> + <div class="td cbi-value-field" style="width:150px"> <input type="button" class="cbi-button cbi-button-edit" onclick="location.href='<%=luci.dispatcher.build_url('admin/services/travelmate/wifiedit')%>?cfg=<%=section%>'" title="<%:Edit this Uplink%>" value="<%:Edit%>"/> <input type="button" class="cbi-button cbi-button-remove" onclick="location.href='<%=luci.dispatcher.build_url('admin/services/travelmate/wifidelete')%>?cfg=<%=section%>'" title="<%:Delete this Uplink%>" value="<%:Delete%>"/> - </td> - </tr> + </div> + </div> <% end end) %> - </table> + </div> </fieldset> <div class="cbi-page-actions right"> <% diff --git a/applications/luci-app-travelmate/luasrc/view/travelmate/wifi_scan.htm b/applications/luci-app-travelmate/luasrc/view/travelmate/wifi_scan.htm index a8f63a17e2..81182b99b4 100644 --- a/applications/luci-app-travelmate/luasrc/view/travelmate/wifi_scan.htm +++ b/applications/luci-app-travelmate/luasrc/view/travelmate/wifi_scan.htm @@ -42,28 +42,28 @@ This is free software, licensed under the Apache License, Version 2.0 <div class="cbi-map"> <h2 name="content"><%:Wireless Scan%></h2> <fieldset class="cbi-section"> - <table class="cbi-section-table" style="empty-cells:hide"> - <tr class="cbi-section-table-titles"> - <th class="cbi-section-table-cell" style="text-align:left"><%:Uplink SSID%></th> - <th class="cbi-section-table-cell" style="text-align:left"><%:Uplink BSSID%></th> - <th class="cbi-section-table-cell" style="text-align:left"><%:Encryption%></th> - <th class="cbi-section-table-cell" style="text-align:left" colspan="2"><%:Signal strength%></th> - </tr> + <div class="table cbi-section-table" style="empty-cells:hide"> + <div class="tr cbi-section-table-titles"> + <div class="th cbi-section-table-cell" style="text-align:left"><%:Uplink SSID%></div> + <div class="th cbi-section-table-cell" style="text-align:left"><%:Uplink BSSID%></div> + <div class="th cbi-section-table-cell" style="text-align:left"><%:Encryption%></div> + <div class="th cbi-section-table-cell" style="text-align:left" colspan="2"><%:Signal strength%></div> + </div> <% for i, net in ipairs(iw.scanlist or { }) do %> - <tr class="cbi-section-table-row cbi-rowstyle-1"> - <td class="cbi-value-field" style="text-align:left"> + <div class="tr cbi-section-table-row cbi-rowstyle-1"> + <div class="td cbi-value-field" style="text-align:left"> <%=net.ssid and utl.pcdata(net.ssid) or "<em>%s</em>" % translate("hidden")%> - </td> - <td class="cbi-value-field" style="text-align:left"> + </div> + <div class="td cbi-value-field" style="text-align:left"> <%=net.bssid and utl.pcdata(net.bssid)%> - </td> - <td class="cbi-value-field" style="text-align:left"> + </div> + <div class="td cbi-value-field" style="text-align:left"> <%=format_wifi_encryption(net.encryption)%> - </td> - <td class="cbi-value-field" style="text-align:left"> + </div> + <div class="td cbi-value-field" style="text-align:left"> <%=percent_wifi_signal(net)%> % - </td> - <td class="cbi-value-field" style="width:100px;text-align:right"> + </div> + <div class="td cbi-value-field" style="width:100px;text-align:right"> <form class="inline" action="<%=luci.dispatcher.build_url('admin/services/travelmate/wifiadd')%>" method="post"> <input type="hidden" name="token" value="<%=token%>"/> <input type="hidden" name="device" value="<%=utl.pcdata(dev)%>"/> @@ -76,10 +76,10 @@ This is free software, licensed under the Apache License, Version 2.0 <% end %> <input class="cbi-button cbi-button-apply" type="submit" value="<%:Add Uplink%>"/> </form> - </td> - </tr> + </div> + </div> <% end %> - </table> + </div> </fieldset> <div class="cbi-page-actions right"> <form class="inline" action="<%=luci.dispatcher.build_url('admin/services/travelmate/wifiscan')%>" method="post"> diff --git a/applications/luci-app-unbound/luasrc/model/cbi/unbound/configure.lua b/applications/luci-app-unbound/luasrc/model/cbi/unbound/configure.lua index bf2b65a0a1..256bbb8392 100644 --- a/applications/luci-app-unbound/luasrc/model/cbi/unbound/configure.lua +++ b/applications/luci-app-unbound/luasrc/model/cbi/unbound/configure.lua @@ -9,7 +9,7 @@ local rlh, rpv, vld, nvd, eds, prt, tlm local ctl, dlk, dom, dty, lfq, wfq, exa local dp6, d64, pfx, qry, qrs local pro, tgr, rsc, rsn, ag2, stt -local rpn, din, dfw +local rpn, din, dfw, ath local ucl = luci.model.uci.cursor() local valman = ucl:get_first("unbound", "unbound", "manual_conf") @@ -100,15 +100,6 @@ if valman ~= "1" then pfx.optional = true pfx:depends({ dns64 = true }) - qry = s1:taboption("basic", Flag, "query_minimize", translate("Query Minimize:"), - translate("Break down query components for limited added privacy")) - qry.rmempty = false - - qrs = s1:taboption("basic", Flag, "query_min_strict", translate("Strict Minimize:"), - translate("Strict version of 'query minimize' but it can break DNS")) - qrs.rmempty = false - qrs:depends({ query_minimize = true }) - prt = s1:taboption("basic", Value, "listen_port", translate("Listening Port:"), translate("Choose Unbounds listening port")) prt.datatype = "port" @@ -216,26 +207,43 @@ if valman ~= "1" then pro = s1:taboption("resource", ListValue, "protocol", translate("Recursion Protocol:"), translate("Chose the protocol recursion queries leave on")) - pro:value("mixed", translate("IP4 and IP6")) - pro:value("ip6_prefer", translate("IP6 Preferred")) + pro:value("default", translate("Default")) pro:value("ip4_only", translate("IP4 Only")) pro:value("ip6_only", translate("IP6 Only")) + pro:value("ip6_prefer", translate("IP6 Preferred")) + pro:value("mixed", translate("IP4 and IP6")) pro.rmempty = false + rsc = s1:taboption("resource", ListValue, "resource", translate("Memory Resource:"), + translate("Use menu System/Processes to observe any memory growth")) + rsc:value("default", translate("Default")) + rsc:value("tiny", translate("Tiny")) + rsc:value("small", translate("Small")) + rsc:value("medium", translate("Medium")) + rsc:value("large", translate("Large")) + rsc.rmempty = false + rsn = s1:taboption("resource", ListValue, "recursion", translate("Recursion Strength:"), translate("Recursion activity affects memory growth and CPU load")) - rsn:value("aggressive", translate("Aggressive")) rsn:value("default", translate("Default")) rsn:value("passive", translate("Passive")) + rsn:value("aggressive", translate("Aggressive")) rsn.rmempty = false - rsc = s1:taboption("resource", ListValue, "resource", translate("Memory Resource:"), - translate("Use menu System/Processes to observe any memory growth")) - rsc:value("large", translate("Large")) - rsc:value("medium", translate("Medium")) - rsc:value("small", translate("Small")) - rsc:value("tiny", translate("Tiny")) - rsc.rmempty = false + qry = s1:taboption("resource", Flag, "query_minimize", translate("Query Minimize:"), + translate("Break down query components for limited added privacy")) + qry.rmempty = false + qry:depends({ recursion = "passive" }) + qry:depends({ recursion = "aggressive" }) + + qrs = s1:taboption("resource", Flag, "query_min_strict", translate("Strict Minimize:"), + translate("Strict version of 'query minimize' but it can break DNS")) + qrs.rmempty = false + qrs:depends({ query_minimize = true }) + + ath = s1:taboption("resource", Flag, "prefetch_root", translate("Prefetch Root:"), + translate("Obtain complete root zone files and install in auth-zone: clause")) + ath.rmempty = false eds = s1:taboption("resource", Value, "edns_size", translate("EDNS Size:"), translate("Limit extended DNS packet size")) diff --git a/applications/luci-app-upnp/luasrc/view/upnp_status.htm b/applications/luci-app-upnp/luasrc/view/upnp_status.htm index 89fdb5e218..1e09225793 100644 --- a/applications/luci-app-upnp/luasrc/view/upnp_status.htm +++ b/applications/luci-app-upnp/luasrc/view/upnp_status.htm @@ -4,8 +4,8 @@ function(x) { var tb = document.getElementById('upnp_status_table'); - if (tb && (idx < tb.rows.length)) - tb.rows[0].parentNode.removeChild(tb.rows[idx]); + if (tb && (idx + 1 < tb.childNodes.length)) + tb.removeChild(tb.childNodes[idx + 1]); } ); } @@ -17,35 +17,21 @@ if (st && tb) { /* clear all rows */ - while( tb.rows.length > 1 ) - tb.deleteRow(1); + while (tb.firstElementChild !== tb.lastElementChild) + tb.removeChild(tb.lastElementChild); - for( var i = 0; i < st.length; i++ ) - { - var tr = tb.insertRow(-1); - tr.className = 'cbi-section-table-row cbi-rowstyle-' + ((i % 2) + 1); + for (var i = 0; i < st.length; i++) + tb.appendChild(E('<div class="tr cbi-section-table-row cbi-rowstyle-%d">'.format((i % 2) + 1), [ + E('<div class="td">', st[i].proto), + E('<div class="td">', st[i].extport), + E('<div class="td">', st[i].intaddr), + E('<div class="td">', st[i].intport), + E('<div class="td">', st[i].descr), + E('<input class="cbi-button cbi-input-remove" type="button" value="<%:Delete%>" onclick="upnp_delete_fwd(%d)" />'.format(st[i].num)) + ])); - tr.insertCell(-1).innerHTML = st[i].proto; - tr.insertCell(-1).innerHTML = st[i].extport; - tr.insertCell(-1).innerHTML = st[i].intaddr; - tr.insertCell(-1).innerHTML = st[i].intport; - tr.insertCell(-1).innerHTML = st[i].descr; - - tr.insertCell(-1).innerHTML = String.format( - '<input class="cbi-button cbi-input-remove" type="button" value="<%:Delete%>" onclick="upnp_delete_fwd(%d)" />', - st[i].num - ); - } - - if( tb.rows.length == 1 ) - { - var tr = tb.insertRow(-1); - tr.className = 'cbi-section-table-row'; - - var td = tr.insertCell(-1); - td.colSpan = 5; - td.innerHTML = '<em><br /><%:There are no active redirects.%></em>'; - } + if (tb.firstElementChild === tb.lastElementChild) + tb.appendChild(E('<div class="tr cbi-section-table-row"><div class="td"><em><br /><%:There are no active redirects.%></em></div></div>')); } } ); @@ -53,17 +39,17 @@ <fieldset class="cbi-section"> <legend><%:Active UPnP Redirects%></legend> - <table class="cbi-section-table" id="upnp_status_table"> - <tr class="cbi-section-table-titles"> - <th class="cbi-section-table-cell"><%:Protocol%></th> - <th class="cbi-section-table-cell"><%:External Port%></th> - <th class="cbi-section-table-cell"><%:Client Address%></th> - <th class="cbi-section-table-cell"><%:Client Port%></th> - <th class="cbi-section-table-cell"><%:Description%></th> - <th class="cbi-section-table-cell"> </th> - </tr> - <tr class="cbi-section-table-row"> - <td colspan="5"><em><br /><%:Collecting data...%></em></td> - </tr> - </table> + <div class="table cbi-section-table" id="upnp_status_table"> + <div class="tr cbi-section-table-titles"> + <div class="th cbi-section-table-cell"><%:Protocol%></div> + <div class="th cbi-section-table-cell"><%:External Port%></div> + <div class="th cbi-section-table-cell"><%:Client Address%></div> + <div class="th cbi-section-table-cell"><%:Client Port%></div> + <div class="th cbi-section-table-cell"><%:Description%></div> + <div class="th cbi-section-table-cell"> </div> + </div> + <div class="tr cbi-section-table-row"> + <div class="td" colspan="5"><em><br /><%:Collecting data...%></em></div> + </div> + </div> </fieldset> diff --git a/applications/luci-app-wireguard/luasrc/view/wireguard.htm b/applications/luci-app-wireguard/luasrc/view/wireguard.htm index 5af6232ae6..64d9955296 100644 --- a/applications/luci-app-wireguard/luasrc/view/wireguard.htm +++ b/applications/luci-app-wireguard/luasrc/view/wireguard.htm @@ -164,43 +164,43 @@ for ikey, iface in pairs(data) do -%> <legend><%:Interface%> <%=ikey%></legend> - <table width="100%" cellspacing="10"> - <tr> - <td width="33%" style="vertical-align:top"><%:Configuration%></td> - <td> - <table> - <tr> - <td id="<%=ikey%>_icon" style="width:16px; text-align:center; padding:3px"> + <div class="table" width="100%" cellspacing="10"> + <div class="tr"> + <div class="td" width="33%" style="vertical-align:top"><%:Configuration%></div> + <div class="td"> + <div class="table"> + <div class="tr"> + <div class="td" id="<%=ikey%>_icon" style="width:16px; text-align:center; padding:3px"> - </td> - <td id="<%=ikey%>_info" style="vertical-align:middle; padding: 3px"> + </div> + <div class="td" id="<%=ikey%>_info" style="vertical-align:middle; padding: 3px"> <em><%:Collecting data...%></em> - </td> - </tr></table> - </td> - </tr> + </div> + </div></div> + </div> + </div> <%- for pkey, peer in pairs(iface.peers) do -%> - <tr> - <td width="33%" style="vertical-align:top"><%:Peer%></td> - <td> - <table> - <tr> - <td id="<%=ikey%>_<%=peer.public_key%>_icon" style="width:16px; text-align:center; padding:3px"> + <div class="tr"> + <div class="td" width="33%" style="vertical-align:top"><%:Peer%></div> + <div class="td"> + <div class="table"> + <div class="tr"> + <div class="td" id="<%=ikey%>_<%=peer.public_key%>_icon" style="width:16px; text-align:center; padding:3px"> <img src="<%=resource%>/icons/tunnel_disabled.png" /><br /> <small>?</small> - </td> - <td id="<%=ikey%>_<%=peer.public_key%>_info" style="vertical-align:middle; padding: 3px"> + </div> + <div class="td" id="<%=ikey%>_<%=peer.public_key%>_info" style="vertical-align:middle; padding: 3px"> <em><%:Collecting data...%></em> - </td> - </tr></table> - </td> - </tr> + </div> + </div></div> + </div> + </div> <%- end -%> - </table> + </div> <%- end -%> |