Skip to content

Commit

Permalink
域名解析和隧道列表增加访问地址,可以点击隧道链接,直接网页打开
Browse files Browse the repository at this point in the history
  • Loading branch information
yisier committed Jan 7, 2025
1 parent 36182e4 commit 78a7336
Show file tree
Hide file tree
Showing 5 changed files with 24 additions and 3 deletions.
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,10 @@ https://natnps.com/


## 更新日志
- 2025-01-07 v0.26.21
- 2025-01-07 v0.26.21
新增:
- 客户端列表页面新增【快捷启动命令】,此命令为连接地址+链接秘钥的base64编码,方便一键启动、一键安装客户端。
- 域名解析和隧道列表增加访问地址,可以点击隧道链接,直接网页打开。 [#234](https://github.com/yisier/nps/issues/234)

优化:
- 修改vkey生成方式,由16位缩短至10位,截取uuid前10位,避免重复。
Expand Down
2 changes: 1 addition & 1 deletion web/static/js/language.js
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@
$.fn.cloudLang = function () {
$.ajax({
type: 'GET',
url: window.nps.web_base_url + '/static/page/languages.xml?v=20240528',
url: window.nps.web_base_url + '/static/page/languages.xml?v=20250107',
dataType: 'xml',
success: function (xml) {
languages['content'] = xml2json($(xml).children())['content'];
Expand Down
6 changes: 6 additions & 0 deletions web/static/page/languages.xml
Original file line number Diff line number Diff line change
Expand Up @@ -396,6 +396,12 @@
<zh-CN>端口</zh-CN>
<en-US>Port</en-US>
</lang>

<lang id="word-accessaddress">
<zh-CN>访问地址</zh-CN>
<en-US>Access address</en-US>
</lang>

<lang id="word-proxytolocal">
<zh-CN>代理到服务器本地</zh-CN>
<en-US>Proxy to server local</en-US>
Expand Down
5 changes: 4 additions & 1 deletion web/views/index/hlist.html
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,10 @@ <h5 langtag="page-hostlist"></h5>
field: 'Host',//域值
title: '<span langtag="word-host"></span>',//标题
halign: 'center',
visible: true//false表示不显示
visible: true,//false表示不显示
formatter: function (value, row, index) {
return "<a href='http://" + row.Host + "' target='_blank'>" + row.Host + "</a>"
}
},
{
field: 'Scheme',//域值
Expand Down
11 changes: 11 additions & 0 deletions web/views/index/list.html
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,17 @@ <h5><span id="langtag"></span><span></span></h5>
sortable: true, //启用排序
visible: true//false表示不显示
},
{
field: 'address',//域值
title: '<span langtag="word-accessaddress"></span>',//标题
halign: 'center',
sortable: false, //启用排序
visible: true,//false表示不显示
formatter: function (value, row, index) {
var address = {{.ip}} + ":" + row.Port
return "<a href='http://" + address + "' target='_blank'>" + address + "</a>"
}
},
{
field: 'Target',//域值
title: '<span langtag="word-target"></span>',//标题
Expand Down

0 comments on commit 78a7336

Please sign in to comment.