-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #4 from jakues/devel
- Loading branch information
Showing
19 changed files
with
303 additions
and
56 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
<%# | ||
Created by Victor Polotebnov ([email protected]) | ||
%> | ||
<% | ||
local ver = require "luci.version" | ||
%> | ||
<div class="footer"> | ||
<div class="container"> | ||
<span> | ||
<a href="https://github.com/tano-systems/luci" target="_blank">Powered by <%= ver.luciname %></a> | <%= ver.luciversion %> | ||
</span> | ||
</div> | ||
</div> | ||
</div> | ||
</div> | ||
</div> | ||
<script type="text/javascript">L.require('menu-tano', null, '${PKG_VERSION}')</script> | ||
</body> | ||
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,101 @@ | ||
<% | ||
|
||
local util = require "luci.util" | ||
local sys = require "luci.sys" | ||
local http = require "luci.http" | ||
local disp = require "luci.dispatcher" | ||
|
||
local boardinfo = util.ubus("system", "board") | ||
local node = disp.context.dispatched | ||
|
||
local request = disp.context.path | ||
local category = request[1] | ||
|
||
local body_data_path = "login" | ||
|
||
if disp.context.authsession and #disp.context.path > 0 then | ||
body_data_path = table.concat(disp.context.path, "-") | ||
end | ||
|
||
-- send as HTML5 | ||
http.prepare_content("text/html") | ||
-%> | ||
|
||
<!DOCTYPE html> | ||
<html lang="<%= luci.i18n.context.lang %>"> | ||
<head> | ||
<meta charset="utf-8"/> | ||
<title> | ||
<%= striptags( (boardinfo.hostname or "?") .. ( (node and node.title) and ' - ' .. translate(node.title) or '')) %> - LuCI | ||
</title> | ||
<meta content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0" name="viewport"/> | ||
<link rel="stylesheet" href="<%= media %>/cascade.css?v=unknown" /> | ||
<script src="<%=url('admin/translations', luci.i18n.context.lang)%>?v=unknown"></script> | ||
<script type="text/javascript" src="<%= resource %>/cbi.js?v=unknown"></script> | ||
<script type="text/javascript"> | ||
document.addEventListener('DOMContentLoaded', function() { | ||
L.require('ui').then(function(ui) { | ||
ui.setIndicatorCustomRenderFn('poll-status', function(id, label, style) { | ||
var circle = E('span', { 'class': 'circle' }); | ||
circle.innerHTML = '<svg viewBox="0 0 1792 1792" xmlns="http://www.w3.org/2000/svg"><path d="M1639 1056q0 5-1 7-64 268-268 434.5t-478 166.5q-146 0-282.5-55t-243.5-157l-129 129q-19 19-45 19t-45-19-19-45v-448q0-26 19-45t45-19h448q26 0 45 19t19 45-19 45l-137 137q71 66 161 102t187 36q134 0 250-65t186-179q11-17 53-117 8-23 30-23h192q13 0 22.5 9.5t9.5 22.5zm25-800v448q0 26-19 45t-45 19h-448q-26 0-45-19t-19-45 19-45l138-138q-148-137-349-137-134 0-250 65t-186 179q-11 17-53 117-8 23-30 23h-199q-13 0-22.5-9.5t-9.5-22.5v-7q65-268 270-434.5t480-166.5q146 0 284 55.5t245 156.5l130-129q19-19 45-19t45 19 19 45z"/></svg>' | ||
return E('div', { 'class': 'xhr-poll-status' }, [ | ||
E('span', { 'class': 'xhr-poll-status-' + style }, [ | ||
circle, E('span', { 'class': 'bar' }) | ||
]), | ||
E('span', { 'class': 'xhr-poll-label'}, _('Auto Refresh')) | ||
]); | ||
}); | ||
ui.setIndicatorCustomRenderFn('uci-changes', function(id, label, style) { | ||
var n = label.match(/\d+/); | ||
if (n === null) | ||
return E('div', {}); | ||
return E('div', { 'class': 'uci-changes' }, [ | ||
E('span', { 'class': 'uci-changes-label' }, _('Unsaved Changes') + ':'), | ||
E('span', { 'class': 'uci-changes-number' }, n[0]) | ||
]); | ||
}); | ||
}); | ||
}); | ||
</script> | ||
<link rel="icon" href="<%= media %>/favicon.png"> | ||
</head> | ||
<body data-path="<%=body_data_path%>"> | ||
<div class="header"> | ||
<div class="container"> | ||
<div class="header-controls"> | ||
<div class="logo"> | ||
<img src="<%= media %>/logo.png" class="logo"/> | ||
</div> | ||
<div id="indicators"></div> | ||
<% if luci.dispatcher.context.authsession then %> | ||
<img src="<%= media %>/fa-bars.svg" id="sidemenu-toggle" class="header-icon menu-icon"/> | ||
<% end %> | ||
</div> | ||
</div> | ||
<div class="additional-info"> | ||
<div class="container"> | ||
<%- if not headers or headers["x-luci-login-required"] ~= "yes" then -%> | ||
<div class="breadcrumbs-wrapper" id="menu-breadcrumbs"></div> | ||
<%- end -%> | ||
<div class="hostname"> | ||
<span class="title"><%:Hostname%>:</span> | ||
<%= striptags(boardinfo.hostname or "?") %> | ||
</div> | ||
</div> | ||
</div> | ||
</div> | ||
<div class="content"> | ||
<div class="container"> | ||
<%- if category then %> | ||
<div class="dn" id="sidemenu"></div> | ||
<% end %> | ||
<div id="maincontent" class="main-content"> | ||
<%- if not headers or headers["x-luci-login-required"] ~= "yes" then -%> | ||
<%- if sys.process.info("uid") == 0 and sys.user.getuser("root") and not sys.user.getpasswd("root") then -%> | ||
<div class="alert-message"> | ||
<h4 align="center"><%:No password set!%></h4> | ||
<p align="center"><%:There is no password set on this router. Please configure a root password to protect the web interface and enable SSH.%></p> | ||
<p align="center"><a class="cbi-button cbi-button-link cbi-button-apply margin-top-15" href="<%=pcdata(luci.dispatcher.build_url('admin/system/admin'))%>"><%:Go to password configuration...%></a></p> | ||
</div> | ||
<%- end -%> | ||
<%- end -%> |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -53,4 +53,4 @@ usbutils | |
whereis | ||
wget | ||
zsh | ||
zoneinfo-asia |
Oops, something went wrong.