1
0
mirror of https://github.com/beego/bee.git synced 2025-07-05 18:20:18 +00:00

bee generate scaffold model

This commit is contained in:
astaxie
2014-08-11 17:01:00 +08:00
parent c58ee3ca2c
commit cd31fe26ed
6 changed files with 359 additions and 23 deletions

View File

@ -8,7 +8,7 @@ import (
// recipe
// admin/recipe
func generateView(vpath, crupath string) {
absvpath := path.Join(crupath, vpath)
absvpath := path.Join(crupath, "views", vpath)
os.MkdirAll(absvpath, os.ModePerm)
cfile := path.Join(absvpath, "index.tpl")
if f, err := os.OpenFile(cfile, os.O_CREATE|os.O_EXCL|os.O_RDWR, 0666); err == nil {