diff options
-rw-r--r-- | modules/luci-mod-admin-full/luasrc/view/admin_network/lease_status.htm | 16 | ||||
-rw-r--r-- | modules/luci-mod-admin-full/luasrc/view/admin_status/index.htm | 8 |
2 files changed, 12 insertions, 12 deletions
diff --git a/modules/luci-mod-admin-full/luasrc/view/admin_network/lease_status.htm b/modules/luci-mod-admin-full/luasrc/view/admin_network/lease_status.htm index f7787dd1e..b4baedff2 100644 --- a/modules/luci-mod-admin-full/luasrc/view/admin_network/lease_status.htm +++ b/modules/luci-mod-admin-full/luasrc/view/admin_network/lease_status.htm @@ -27,14 +27,12 @@ { var timestr; - if (st[0][i].expires <= 0) - { + if (st[0][i].expires === false) + timestr = '<em><%:unlimited%></em>'; + else if (st[0][i].expires <= 0) timestr = '<em><%:expired%></em>'; - } else - { timestr = String.format('%t', st[0][i].expires); - } var tr = tb.insertRow(-1); tr.className = 'cbi-section-table-row cbi-rowstyle-' + ((i % 2) + 1); @@ -69,14 +67,12 @@ { var timestr; - if (st[1][i].expires <= 0) - { + if (st[1][i].expires === false) + timestr = '<em><%:unlimited%></em>'; + else if (st[1][i].expires <= 0) timestr = '<em><%:expired%></em>'; - } else - { timestr = String.format('%t', st[1][i].expires); - } var tr = tb6.insertRow(-1); tr.className = 'cbi-section-table-row cbi-rowstyle-' + ((i % 2) + 1); diff --git a/modules/luci-mod-admin-full/luasrc/view/admin_status/index.htm b/modules/luci-mod-admin-full/luasrc/view/admin_status/index.htm index eb4648806..8976e30cb 100644 --- a/modules/luci-mod-admin-full/luasrc/view/admin_status/index.htm +++ b/modules/luci-mod-admin-full/luasrc/view/admin_status/index.htm @@ -341,7 +341,9 @@ { var timestr; - if (info.leases[i].expires <= 0) + if (info.leases[i].expires === false) + timestr = '<em><%:unlimited%></em>'; + else if (info.leases[i].expires <= 0) timestr = '<em><%:expired%></em>'; else timestr = String.format('%t', info.leases[i].expires); @@ -379,7 +381,9 @@ { var timestr; - if (info.leases6[i].expires <= 0) + if (info.leases6[i].expires === false) + timestr = '<em><%:unlimited%></em>'; + else if (info.leases6[i].expires <= 0) timestr = '<em><%:expired%></em>'; else timestr = String.format('%t', info.leases6[i].expires); |