Skip to content

Commit

Permalink
add version
Browse files Browse the repository at this point in the history
  • Loading branch information
fesiong committed Jan 20, 2021
1 parent bfc43e1 commit 87a637c
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 4 deletions.
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,5 @@
vendor
config.json
goblog
/doc
/doc
/test
2 changes: 2 additions & 0 deletions config/constant.go
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
package config

const Version = "0.5.0"

const StatusOK = 0
const StatusFailed = -1
const StatusNoLogin = 1001
2 changes: 2 additions & 0 deletions controller/common.go
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,8 @@ func InternalServerError(ctx iris.Context) {
}

func Common(ctx iris.Context) {
ctx.ViewData("version", config.Version)

ctx.ViewData("SiteName", config.ServerConfig.SiteName)
ctx.ViewData("SiteIcp", config.ServerConfig.Icp)
if config.DB != nil {
Expand Down
6 changes: 3 additions & 3 deletions template/partial/author.html
Original file line number Diff line number Diff line change
Expand Up @@ -10,18 +10,18 @@
<tr>
<td>当前版本</td>
<td>
irisweb-v1.0
irisweb-v{{version}}
</td>
</tr>
<tr>
<td>开发者</td>
<td>
Fesion
Sinclair Liang
</td>
</tr>
<tr>
<td>主要特色</td>
<td>简单易用的irisweb框架开发的golang版本博客</td>
<td>简单易用的irisweb框架开发的golang版本博客,同时支持企业站使用,支持微信小程序、百度智能小程序等多端小程序接入</td>
</tr>
<tr>
<td>GitHub</td>
Expand Down

0 comments on commit 87a637c

Please sign in to comment.