mirror of
https://github.com/yhl452493373/frps-panel.git
synced 2026-04-04 06:16:59 +08:00
add version info and GitHub link on index
This commit is contained in:
@@ -108,6 +108,11 @@ section.proxy-list .proxy-info .layui-row .layui-row > div:first-child {
|
|||||||
border-color: #fde2e2;
|
border-color: #fde2e2;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.version a,
|
||||||
|
.version span {
|
||||||
|
color: #99a9bf;
|
||||||
|
}
|
||||||
|
|
||||||
@media (prefers-color-scheme: dark) {
|
@media (prefers-color-scheme: dark) {
|
||||||
.layui-bg-blue {
|
.layui-bg-blue {
|
||||||
background-color: #395c74 !important;
|
background-color: #395c74 !important;
|
||||||
|
|||||||
@@ -38,6 +38,7 @@ var loadServerInfo = (function ($) {
|
|||||||
function renderServerInfo(data) {
|
function renderServerInfo(data) {
|
||||||
var html = layui.laytpl($('#serverInfoTemplate').html()).render(data);
|
var html = layui.laytpl($('#serverInfoTemplate').html()).render(data);
|
||||||
$('#content').html(html);
|
$('#content').html(html);
|
||||||
|
$('#frpVersion').text(data.version);
|
||||||
|
|
||||||
renderTrafficChart(data);
|
renderTrafficChart(data);
|
||||||
renderCountChart(data);
|
renderCountChart(data);
|
||||||
|
|||||||
@@ -68,7 +68,11 @@
|
|||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
<div class="version">1.0.0</div>
|
<div class="version">
|
||||||
|
<a href="https://github.com/fatedier/frp" target="_blank">Frp <span id="frpVersion"></span></a>
|
||||||
|
<span> | </span>
|
||||||
|
<a href="https://github.com/yhl452493373/frps-panel" target="_blank">${ .FrpsPanel } v${ .version }</a>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="layui-body" id="content"></div>
|
<div class="layui-body" id="content"></div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -13,7 +13,7 @@ import (
|
|||||||
"strings"
|
"strings"
|
||||||
)
|
)
|
||||||
|
|
||||||
const version = "0.0.2"
|
const version = "1.4.0"
|
||||||
|
|
||||||
var (
|
var (
|
||||||
showVersion bool
|
showVersion bool
|
||||||
@@ -55,6 +55,7 @@ var rootCmd = &cobra.Command{
|
|||||||
Subdomains: subdomains,
|
Subdomains: subdomains,
|
||||||
ConfigFile: configFile,
|
ConfigFile: configFile,
|
||||||
IniFile: iniFile,
|
IniFile: iniFile,
|
||||||
|
Version: version,
|
||||||
})
|
})
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
|
|||||||
@@ -215,6 +215,7 @@ func (c *HandleController) MakeManagerFunc() func(context *gin.Context) {
|
|||||||
"Addr": ginI18n.MustGetMessage(context, "Addr"),
|
"Addr": ginI18n.MustGetMessage(context, "Addr"),
|
||||||
"LastStart": ginI18n.MustGetMessage(context, "Last Start"),
|
"LastStart": ginI18n.MustGetMessage(context, "Last Start"),
|
||||||
"LastClose": ginI18n.MustGetMessage(context, "Last Close"),
|
"LastClose": ginI18n.MustGetMessage(context, "Last Close"),
|
||||||
|
"version": c.Version,
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -20,6 +20,7 @@ type HandleController struct {
|
|||||||
Subdomains map[string][]string
|
Subdomains map[string][]string
|
||||||
ConfigFile string
|
ConfigFile string
|
||||||
IniFile *ini.File
|
IniFile *ini.File
|
||||||
|
Version string
|
||||||
}
|
}
|
||||||
|
|
||||||
func NewHandleController(config *HandleController) *HandleController {
|
func NewHandleController(config *HandleController) *HandleController {
|
||||||
|
|||||||
Reference in New Issue
Block a user