mirror of
https://github.com/logicog/RTLPlayground.git
synced 2026-08-30 14:52:51 +08:00
system: show the hardware model on the System page
machine.machine_name is already reported in /information.json as hw_ver; surface it read-only on the System Settings page so the exact build target is visible in the UI, without adding a redundant JSON field.
This commit is contained in:
@@ -138,6 +138,7 @@ var LANG = {
|
||||
sys_tab_console: 'Console',
|
||||
sys_heading: 'System Settings',
|
||||
sys_ip: 'IP address:',
|
||||
sys_model: 'Model:',
|
||||
sys_hostname: 'Hostname:',
|
||||
sys_apply: 'Apply',
|
||||
sys_netmask: 'Netmask:',
|
||||
@@ -319,6 +320,7 @@ var LANG = {
|
||||
sys_tab_console: 'コンソール',
|
||||
sys_heading: 'システム設定',
|
||||
sys_ip: 'IP アドレス:',
|
||||
sys_model: 'モデル:',
|
||||
sys_hostname: 'ホスト名:',
|
||||
sys_apply: '適用',
|
||||
sys_netmask: 'ネットマスク:',
|
||||
@@ -500,6 +502,7 @@ var LANG = {
|
||||
sys_tab_console: '控制台',
|
||||
sys_heading: '系统设置',
|
||||
sys_ip: 'IP 地址:',
|
||||
sys_model: '型号:',
|
||||
sys_hostname: '主机名:',
|
||||
sys_apply: '应用',
|
||||
sys_netmask: '子网掩码:',
|
||||
|
||||
@@ -30,6 +30,10 @@
|
||||
<div class="rcol"> <input id="hostname" type="text" maxlength="23" size="20"/>
|
||||
<button onclick="hostSub()" data-i18n="sys_apply">Apply</button></div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="lcol"> <label data-i18n="sys_model">Model:</label></div>
|
||||
<div class="rcol"><span id="model"></span></div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="lcol"> <label for="ip" data-i18n="sys_ip">IP address:</label></div>
|
||||
<div class="rcol"> <input id="ip" class="ip" type="text" minlength="7" maxlength="15" size="15"/></div>
|
||||
|
||||
@@ -132,6 +132,7 @@ function fetchIP() {
|
||||
document.getElementById("netmask").value=s.ip_netmask;
|
||||
document.getElementById("gw").value=s.ip_gateway;
|
||||
if (document.getElementById("hostname")) document.getElementById("hostname").value = s.hostname || "";
|
||||
if (document.getElementById("model")) document.getElementById("model").textContent = s.hw_ver || "";
|
||||
clearInterval(systemInterval);
|
||||
// Fetch and populate the config textbox
|
||||
fetchConfig().then((configText) => {
|
||||
|
||||
Reference in New Issue
Block a user