Merge pull request #5905 from ldir-EDB0/dashboard

luci-mod-dashboard: show IPv6 connection uptime
This commit is contained in:
Jo-Philipp Wich 2022-07-30 13:58:45 +02:00 committed by GitHub
commit b0b9a34f8b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 5 additions and 3 deletions

View file

@ -146,6 +146,8 @@ return baseclass.extend({
var ifc = data[i];
if (v6) {
var uptime = ifc.getUptime();
this.params.internet.v6.uptime.value = (uptime > 0) ? '%t'.format(uptime) : '-';
this.params.internet.v6.ipprefixv6.value = ifc.getIP6Prefix() || '-';
this.params.internet.v6.gatewayv6.value = ifc.getGateway6Addr() || '-';
this.params.internet.v6.protocol.value= ifc.getI18n() || E('em', _('Not connected'));
@ -178,7 +180,7 @@ return baseclass.extend({
},
uptime: {
title: _('Connected since'),
title: _('Uptime'),
visible: true,
value: '-'
},
@ -218,7 +220,7 @@ return baseclass.extend({
},
uptime: {
title: _('Connected since'),
title: _('Uptime'),
visible: true,
value: '-'
},

View file

@ -30,7 +30,7 @@ msgstr ""
#: modules/luci-mod-dashboard/htdocs/luci-static/resources/view/dashboard/include/10_router.js:181
#: modules/luci-mod-dashboard/htdocs/luci-static/resources/view/dashboard/include/10_router.js:221
msgid "Connected since"
msgid "Uptime"
msgstr ""
#: modules/luci-mod-dashboard/htdocs/luci-static/resources/view/dashboard/include/20_lan.js:13