mirror of
https://github.com/h44z/wg-portal
synced 2025-02-26 05:49:14 +00:00
Show version on frontend (#346)
This commit is contained in:
parent
c2658534b0
commit
2cea2e477a
@ -10,6 +10,7 @@ import (
|
|||||||
"net/url"
|
"net/url"
|
||||||
|
|
||||||
"github.com/gin-gonic/gin"
|
"github.com/gin-gonic/gin"
|
||||||
|
"github.com/h44z/wg-portal/internal"
|
||||||
"github.com/h44z/wg-portal/internal/app"
|
"github.com/h44z/wg-portal/internal/app"
|
||||||
"github.com/h44z/wg-portal/internal/app/api/v0/model"
|
"github.com/h44z/wg-portal/internal/app/api/v0/model"
|
||||||
)
|
)
|
||||||
@ -70,7 +71,7 @@ func (e configEndpoint) handleConfigJsGet() gin.HandlerFunc {
|
|||||||
buf := &bytes.Buffer{}
|
buf := &bytes.Buffer{}
|
||||||
err := e.tpl.ExecuteTemplate(buf, "frontend_config.js.gotpl", gin.H{
|
err := e.tpl.ExecuteTemplate(buf, "frontend_config.js.gotpl", gin.H{
|
||||||
"BackendUrl": backendUrl,
|
"BackendUrl": backendUrl,
|
||||||
"Version": "unknown",
|
"Version": internal.Version,
|
||||||
"SiteTitle": e.app.Config.Web.SiteTitle,
|
"SiteTitle": e.app.Config.Web.SiteTitle,
|
||||||
"SiteCompanyName": e.app.Config.Web.SiteCompanyName,
|
"SiteCompanyName": e.app.Config.Web.SiteCompanyName,
|
||||||
})
|
})
|
||||||
|
Loading…
Reference in New Issue
Block a user