mirror of
https://github.com/astaxie/beego.git
synced 2024-11-22 17:40:55 +00:00
Add TplPrefix to TplName also.
This commit is contained in:
parent
fee06a23bd
commit
0943ef9e74
@ -227,10 +227,10 @@ func (c *Controller) renderTemplate() (bytes.Buffer, error) {
|
|||||||
var buf bytes.Buffer
|
var buf bytes.Buffer
|
||||||
if c.TplName == "" {
|
if c.TplName == "" {
|
||||||
c.TplName = strings.ToLower(c.controllerName) + "/" + strings.ToLower(c.actionName) + "." + c.TplExt
|
c.TplName = strings.ToLower(c.controllerName) + "/" + strings.ToLower(c.actionName) + "." + c.TplExt
|
||||||
|
}
|
||||||
if c.TplPrefix != "" {
|
if c.TplPrefix != "" {
|
||||||
c.TplName = c.TplPrefix + c.TplName
|
c.TplName = c.TplPrefix + c.TplName
|
||||||
}
|
}
|
||||||
}
|
|
||||||
if BConfig.RunMode == DEV {
|
if BConfig.RunMode == DEV {
|
||||||
buildFiles := []string{c.TplName}
|
buildFiles := []string{c.TplName}
|
||||||
if c.Layout != "" {
|
if c.Layout != "" {
|
||||||
|
Loading…
Reference in New Issue
Block a user