diff options
author | Unknown <joe2010xtmf@163.com> | 2014-04-08 12:41:33 -0400 |
---|---|---|
committer | Unknown <joe2010xtmf@163.com> | 2014-04-08 12:41:33 -0400 |
commit | 115a349131242201953a3f5693141679049355c6 (patch) | |
tree | 5509a46e5d6866cd573c03a41484d58c12cb6cae /modules | |
parent | 22feddf804c7fbf3418cbbc8e7302da271da4e5a (diff) |
Fix #67
Diffstat (limited to 'modules')
-rw-r--r-- | modules/base/conf.go | 1 | ||||
-rw-r--r-- | modules/base/template.go | 3 |
2 files changed, 4 insertions, 0 deletions
diff --git a/modules/base/conf.go b/modules/base/conf.go index 69df49dc..871595e4 100644 --- a/modules/base/conf.go +++ b/modules/base/conf.go @@ -43,6 +43,7 @@ var ( AppName string AppLogo string AppUrl string + IsProdMode bool Domain string SecretKey string RunUser string diff --git a/modules/base/template.go b/modules/base/template.go index 6cd8ade6..5a42107c 100644 --- a/modules/base/template.go +++ b/modules/base/template.go @@ -56,6 +56,9 @@ var TemplateFuncs template.FuncMap = map[string]interface{}{ "AppDomain": func() string { return Domain }, + "IsProdMode": func() bool { + return IsProdMode + }, "LoadTimes": func(startTime time.Time) string { return fmt.Sprint(time.Since(startTime).Nanoseconds()/1e6) + "ms" }, |