Compatible with revel 0.18
This commit is contained in:
@ -46,14 +46,17 @@ func (c Attach) uploadAttach(noteId string) (re info.Re) {
|
|||||||
return re
|
return re
|
||||||
}
|
}
|
||||||
|
|
||||||
file, handel, err := c.Request.FormFile("file")
|
var data []byte
|
||||||
if err != nil {
|
c.Params.Bind(&data, "file")
|
||||||
return re
|
|
||||||
}
|
|
||||||
defer file.Close()
|
|
||||||
|
|
||||||
data, err := ioutil.ReadAll(file)
|
// file, handel, err := c.Request.FormFile("file")
|
||||||
if err != nil {
|
// if err != nil {
|
||||||
|
// return re
|
||||||
|
// }
|
||||||
|
// defer file.Close()
|
||||||
|
|
||||||
|
// data, err := ioutil.ReadAll(file)
|
||||||
|
if data == nil || len(data) == 0 {
|
||||||
return re
|
return re
|
||||||
}
|
}
|
||||||
// > 5M?
|
// > 5M?
|
||||||
@ -71,10 +74,13 @@ func (c Attach) uploadAttach(noteId string) (re info.Re) {
|
|||||||
newGuid := NewGuid()
|
newGuid := NewGuid()
|
||||||
filePath := "files/" + GetRandomFilePath(c.GetUserId(), newGuid) + "/attachs"
|
filePath := "files/" + GetRandomFilePath(c.GetUserId(), newGuid) + "/attachs"
|
||||||
dir := revel.BasePath + "/" + filePath
|
dir := revel.BasePath + "/" + filePath
|
||||||
err = os.MkdirAll(dir, 0755)
|
err := os.MkdirAll(dir, 0755)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return re
|
return re
|
||||||
}
|
}
|
||||||
|
|
||||||
|
handel := c.Params.Files["file"][0]
|
||||||
|
|
||||||
// 生成新的文件名
|
// 生成新的文件名
|
||||||
filename := handel.Filename
|
filename := handel.Filename
|
||||||
_, ext := SplitFilename(filename) // .doc
|
_, ext := SplitFilename(filename) // .doc
|
||||||
|
@ -77,7 +77,7 @@ func (c Blog) e404(themePath string) revel.Result {
|
|||||||
// life.leanote.com
|
// life.leanote.com
|
||||||
// lealife.com
|
// lealife.com
|
||||||
func (c Blog) domain() (ok bool, userBlog info.UserBlog) {
|
func (c Blog) domain() (ok bool, userBlog info.UserBlog) {
|
||||||
host := c.Request.Request.Host // a.cc.com:9000
|
host := c.Request.Host // a.cc.com:9000
|
||||||
hostArr := strings.Split(host, ".")
|
hostArr := strings.Split(host, ".")
|
||||||
if strings.Contains(host, configService.GetDefaultDomain()) {
|
if strings.Contains(host, configService.GetDefaultDomain()) {
|
||||||
// 有二级域名 a.leanoe.com 3个
|
// 有二级域名 a.leanoe.com 3个
|
||||||
|
@ -14,6 +14,7 @@ import (
|
|||||||
// "path"
|
// "path"
|
||||||
// "strconv"
|
// "strconv"
|
||||||
"net/http"
|
"net/http"
|
||||||
|
"io"
|
||||||
)
|
)
|
||||||
|
|
||||||
// 验证码服务
|
// 验证码服务
|
||||||
@ -30,7 +31,8 @@ func (r Ca) Apply(req *revel.Request, resp *revel.Response) {
|
|||||||
func (c Captcha) Get() revel.Result {
|
func (c Captcha) Get() revel.Result {
|
||||||
c.Response.ContentType = "image/png"
|
c.Response.ContentType = "image/png"
|
||||||
image, str := captcha.Fetch()
|
image, str := captcha.Fetch()
|
||||||
image.WriteTo(c.Response.Out)
|
out := io.Writer(c.Response.GetWriter())
|
||||||
|
image.WriteTo(out)
|
||||||
|
|
||||||
sessionId := c.Session["_ID"]
|
sessionId := c.Session["_ID"]
|
||||||
// LogJ(c.Session)
|
// LogJ(c.Session)
|
||||||
|
@ -97,11 +97,27 @@ func (c File) uploadImage(from, albumId string) (re info.Re) {
|
|||||||
re.Ok = Ok
|
re.Ok = Ok
|
||||||
}()
|
}()
|
||||||
|
|
||||||
file, handel, err := c.Request.FormFile("file")
|
// file, handel, err := c.Request.FormFile("file")
|
||||||
if err != nil {
|
// if err != nil {
|
||||||
|
// return re
|
||||||
|
// }
|
||||||
|
// defer file.Close()
|
||||||
|
|
||||||
|
var data []byte
|
||||||
|
c.Params.Bind(&data, "file")
|
||||||
|
handel := c.Params.Files["file"][0]
|
||||||
|
if data == nil || len(data) == 0 {
|
||||||
return re
|
return re
|
||||||
}
|
}
|
||||||
defer file.Close()
|
|
||||||
|
// file, handel, err := c.Request.FormFile("file")
|
||||||
|
// if err != nil {
|
||||||
|
// return re
|
||||||
|
// }
|
||||||
|
// defer file.Close()
|
||||||
|
|
||||||
|
// data, err := ioutil.ReadAll(file)
|
||||||
|
|
||||||
|
|
||||||
// 生成上传路径
|
// 生成上传路径
|
||||||
newGuid := NewGuid()
|
newGuid := NewGuid()
|
||||||
@ -116,7 +132,7 @@ func (c File) uploadImage(from, albumId string) (re info.Re) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
dir := revel.BasePath + "/" + fileUrlPath
|
dir := revel.BasePath + "/" + fileUrlPath
|
||||||
err = os.MkdirAll(dir, 0755)
|
err := os.MkdirAll(dir, 0755)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return re
|
return re
|
||||||
}
|
}
|
||||||
@ -136,11 +152,11 @@ func (c File) uploadImage(from, albumId string) (re info.Re) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
filename = newGuid + ext
|
filename = newGuid + ext
|
||||||
data, err := ioutil.ReadAll(file)
|
// data, err := ioutil.ReadAll(file)
|
||||||
if err != nil {
|
// if err != nil {
|
||||||
LogJ(err)
|
// LogJ(err)
|
||||||
return re
|
// return re
|
||||||
}
|
// }
|
||||||
|
|
||||||
var maxFileSize float64
|
var maxFileSize float64
|
||||||
if from == "logo" {
|
if from == "logo" {
|
||||||
|
@ -53,16 +53,23 @@ func (c ApiBaseContrller) uploadAttach(name string, noteId string) (ok bool, msg
|
|||||||
}
|
}
|
||||||
*/
|
*/
|
||||||
|
|
||||||
file, handel, err := c.Request.FormFile(name)
|
var data []byte
|
||||||
if err != nil {
|
c.Params.Bind(&data, name)
|
||||||
|
handel := c.Params.Files[name][0]
|
||||||
|
if data == nil || len(data) == 0 {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
defer file.Close()
|
|
||||||
|
|
||||||
data, err := ioutil.ReadAll(file)
|
// file, handel, err := c.Request.FormFile(name)
|
||||||
if err != nil {
|
// if err != nil {
|
||||||
return
|
// return
|
||||||
}
|
// }
|
||||||
|
// defer file.Close()
|
||||||
|
|
||||||
|
// data, err := ioutil.ReadAll(file)
|
||||||
|
// if err != nil {
|
||||||
|
// return
|
||||||
|
// }
|
||||||
// > 5M?
|
// > 5M?
|
||||||
maxFileSize := configService.GetUploadSize("uploadAttachSize")
|
maxFileSize := configService.GetUploadSize("uploadAttachSize")
|
||||||
if maxFileSize <= 0 {
|
if maxFileSize <= 0 {
|
||||||
@ -79,7 +86,7 @@ func (c ApiBaseContrller) uploadAttach(name string, noteId string) (ok bool, msg
|
|||||||
filePath := "files/" + GetRandomFilePath(userId, newGuid) + "/attachs"
|
filePath := "files/" + GetRandomFilePath(userId, newGuid) + "/attachs"
|
||||||
|
|
||||||
dir := revel.BasePath + "/" + filePath
|
dir := revel.BasePath + "/" + filePath
|
||||||
err = os.MkdirAll(dir, 0755)
|
err := os.MkdirAll(dir, 0755)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
@ -122,11 +129,18 @@ func (c ApiBaseContrller) upload(name string, noteId string, isAttach bool) (ok
|
|||||||
if isAttach {
|
if isAttach {
|
||||||
return c.uploadAttach(name, noteId)
|
return c.uploadAttach(name, noteId)
|
||||||
}
|
}
|
||||||
file, handel, err := c.Request.FormFile(name)
|
// file, handel, err := c.Request.FormFile(name)
|
||||||
if err != nil {
|
// if err != nil {
|
||||||
|
// return
|
||||||
|
// }
|
||||||
|
// defer file.Close()
|
||||||
|
|
||||||
|
var data []byte
|
||||||
|
c.Params.Bind(&data, name)
|
||||||
|
handel := c.Params.Files[name][0]
|
||||||
|
if data == nil || len(data) == 0 {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
defer file.Close()
|
|
||||||
|
|
||||||
newGuid := NewGuid()
|
newGuid := NewGuid()
|
||||||
// 生成上传路径
|
// 生成上传路径
|
||||||
@ -135,7 +149,7 @@ func (c ApiBaseContrller) upload(name string, noteId string, isAttach bool) (ok
|
|||||||
fileUrlPath := "files/" + GetRandomFilePath(userId, newGuid) + "/images"
|
fileUrlPath := "files/" + GetRandomFilePath(userId, newGuid) + "/images"
|
||||||
|
|
||||||
dir := revel.BasePath + "/" + fileUrlPath
|
dir := revel.BasePath + "/" + fileUrlPath
|
||||||
err = os.MkdirAll(dir, 0755)
|
err := os.MkdirAll(dir, 0755)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
@ -148,10 +162,10 @@ func (c ApiBaseContrller) upload(name string, noteId string, isAttach bool) (ok
|
|||||||
// }
|
// }
|
||||||
|
|
||||||
filename = newGuid + ext
|
filename = newGuid + ext
|
||||||
data, err := ioutil.ReadAll(file)
|
// data, err := ioutil.ReadAll(file)
|
||||||
if err != nil {
|
// if err != nil {
|
||||||
return
|
// return
|
||||||
}
|
// }
|
||||||
|
|
||||||
maxFileSize := configService.GetUploadSize("uploadImageSize")
|
maxFileSize := configService.GetUploadSize("uploadImageSize")
|
||||||
if maxFileSize <= 0 {
|
if maxFileSize <= 0 {
|
||||||
|
@ -104,16 +104,23 @@ func (c ApiUser) uploadImage() (ok bool, msg, url string) {
|
|||||||
var fileUrlPath = ""
|
var fileUrlPath = ""
|
||||||
ok = false
|
ok = false
|
||||||
|
|
||||||
file, handel, err := c.Request.FormFile("file")
|
var data []byte
|
||||||
if err != nil {
|
c.Params.Bind(&data, "file")
|
||||||
|
handel := c.Params.Files["file"][0]
|
||||||
|
if data == nil || len(data) == 0 {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
defer file.Close()
|
|
||||||
|
// file, handel, err := c.Request.FormFile("file")
|
||||||
|
// if err != nil {
|
||||||
|
// return
|
||||||
|
// }
|
||||||
|
// defer file.Close()
|
||||||
// 生成上传路径
|
// 生成上传路径
|
||||||
fileUrlPath = "public/upload/" + c.getUserId() + "/images/logo"
|
fileUrlPath = "public/upload/" + c.getUserId() + "/images/logo"
|
||||||
|
|
||||||
dir := revel.BasePath + "/" + fileUrlPath
|
dir := revel.BasePath + "/" + fileUrlPath
|
||||||
err = os.MkdirAll(dir, 0755)
|
err := os.MkdirAll(dir, 0755)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
@ -129,11 +136,11 @@ func (c ApiUser) uploadImage() (ok bool, msg, url string) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
filename = NewGuid() + ext
|
filename = NewGuid() + ext
|
||||||
data, err := ioutil.ReadAll(file)
|
// data, err := ioutil.ReadAll(file)
|
||||||
if err != nil {
|
// if err != nil {
|
||||||
LogJ(err)
|
// LogJ(err)
|
||||||
return
|
// return
|
||||||
}
|
// }
|
||||||
|
|
||||||
// > 5M?
|
// > 5M?
|
||||||
if len(data) > 5*1024*1024 {
|
if len(data) > 5*1024*1024 {
|
||||||
|
@ -351,14 +351,21 @@ func (c MemberBlog) uploadImage(themeId string) (re info.Re) {
|
|||||||
re.Ok = Ok
|
re.Ok = Ok
|
||||||
}()
|
}()
|
||||||
|
|
||||||
file, handel, err := c.Request.FormFile("file")
|
var data []byte
|
||||||
if err != nil {
|
c.Params.Bind(&data, "file")
|
||||||
|
handel := c.Params.Files["file"][0]
|
||||||
|
if data == nil || len(data) == 0 {
|
||||||
return re
|
return re
|
||||||
}
|
}
|
||||||
defer file.Close()
|
|
||||||
|
// file, handel, err := c.Request.FormFile("file")
|
||||||
|
// if err != nil {
|
||||||
|
// return re
|
||||||
|
// }
|
||||||
|
// defer file.Close()
|
||||||
// 生成上传路径
|
// 生成上传路径
|
||||||
dir := themeService.GetThemeAbsolutePath(c.GetUserId(), themeId) + "/images"
|
dir := themeService.GetThemeAbsolutePath(c.GetUserId(), themeId) + "/images"
|
||||||
err = os.MkdirAll(dir, 0755)
|
err := os.MkdirAll(dir, 0755)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return re
|
return re
|
||||||
}
|
}
|
||||||
@ -374,11 +381,11 @@ func (c MemberBlog) uploadImage(themeId string) (re info.Re) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
filename = filename
|
filename = filename
|
||||||
data, err := ioutil.ReadAll(file)
|
// data, err := ioutil.ReadAll(file)
|
||||||
if err != nil {
|
// if err != nil {
|
||||||
LogJ(err)
|
// LogJ(err)
|
||||||
return re
|
// return re
|
||||||
}
|
// }
|
||||||
|
|
||||||
// > 2M?
|
// > 2M?
|
||||||
if len(data) > 5*1024*1024 {
|
if len(data) > 5*1024*1024 {
|
||||||
@ -441,17 +448,24 @@ func (c MemberBlog) ExportTheme(themeId string) revel.Result {
|
|||||||
func (c MemberBlog) ImportTheme() revel.Result {
|
func (c MemberBlog) ImportTheme() revel.Result {
|
||||||
re := info.NewRe()
|
re := info.NewRe()
|
||||||
|
|
||||||
file, handel, err := c.Request.FormFile("file")
|
var data []byte
|
||||||
if err != nil {
|
c.Params.Bind(&data, "file")
|
||||||
re.Msg = fmt.Sprintf("%v", err)
|
handel := c.Params.Files["file"][0]
|
||||||
|
if data == nil || len(data) == 0 {
|
||||||
return c.RenderJSON(re)
|
return c.RenderJSON(re)
|
||||||
}
|
}
|
||||||
|
|
||||||
defer file.Close()
|
// file, handel, err := c.Request.FormFile("file")
|
||||||
|
// if err != nil {
|
||||||
|
// re.Msg = fmt.Sprintf("%v", err)
|
||||||
|
// return c.RenderJSON(re)
|
||||||
|
// }
|
||||||
|
|
||||||
|
// defer file.Close()
|
||||||
// 生成上传路径
|
// 生成上传路径
|
||||||
userId := c.GetUserId()
|
userId := c.GetUserId()
|
||||||
dir := revel.BasePath + "/public/upload/" + userId + "/tmp"
|
dir := revel.BasePath + "/public/upload/" + userId + "/tmp"
|
||||||
err = os.MkdirAll(dir, 0755)
|
err := os.MkdirAll(dir, 0755)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
re.Msg = fmt.Sprintf("%v", err)
|
re.Msg = fmt.Sprintf("%v", err)
|
||||||
return c.RenderJSON(re)
|
return c.RenderJSON(re)
|
||||||
@ -467,10 +481,10 @@ func (c MemberBlog) ImportTheme() revel.Result {
|
|||||||
}
|
}
|
||||||
|
|
||||||
filename = filename
|
filename = filename
|
||||||
data, err := ioutil.ReadAll(file)
|
// data, err := ioutil.ReadAll(file)
|
||||||
if err != nil {
|
// if err != nil {
|
||||||
return c.RenderJSON(re)
|
// return c.RenderJSON(re)
|
||||||
}
|
// }
|
||||||
|
|
||||||
// > 10M?
|
// > 10M?
|
||||||
if len(data) > 10*1024*1024 {
|
if len(data) > 10*1024*1024 {
|
||||||
|
@ -104,7 +104,7 @@ func (r *RenderTemplateResult) Apply(req *revel.Request, resp *revel.Response) {
|
|||||||
chunked := revel.Config.BoolDefault("results.chunked", false)
|
chunked := revel.Config.BoolDefault("results.chunked", false)
|
||||||
|
|
||||||
// If it's a HEAD request, throw away the bytes.
|
// If it's a HEAD request, throw away the bytes.
|
||||||
out := io.Writer(resp.Out)
|
out := io.Writer(resp.GetWriter())
|
||||||
if req.Method == "HEAD" {
|
if req.Method == "HEAD" {
|
||||||
out = ioutil.Discard
|
out = ioutil.Discard
|
||||||
}
|
}
|
||||||
@ -289,7 +289,7 @@ func (r ErrorResult) Apply(req *revel.Request, resp *revel.Response) {
|
|||||||
// 不是preview就不要显示错误了
|
// 不是preview就不要显示错误了
|
||||||
if r.IsPreview {
|
if r.IsPreview {
|
||||||
var b bytes.Buffer
|
var b bytes.Buffer
|
||||||
out := io.Writer(resp.Out)
|
out := io.Writer(resp.GetWriter())
|
||||||
// out = ioutil.Discard
|
// out = ioutil.Discard
|
||||||
err = tmpl.Execute(&b, r.ViewArgs)
|
err = tmpl.Execute(&b, r.ViewArgs)
|
||||||
resp.WriteHeader(http.StatusOK, "text/html; charset=utf-8")
|
resp.WriteHeader(http.StatusOK, "text/html; charset=utf-8")
|
||||||
|
@ -210,10 +210,10 @@ func hasAcceptLanguageHeader(request *revel.Request) (bool, string) {
|
|||||||
|
|
||||||
// Determine whether the given request has a valid language cookie value.
|
// Determine whether the given request has a valid language cookie value.
|
||||||
func hasLocaleCookie(request *revel.Request) (bool, string) {
|
func hasLocaleCookie(request *revel.Request) (bool, string) {
|
||||||
if request != nil && request.Cookies() != nil {
|
if request != nil {
|
||||||
name := revel.Config.StringDefault(localeCookieConfigKey, revel.CookiePrefix+"_LANG")
|
name := revel.Config.StringDefault(localeCookieConfigKey, revel.CookiePrefix+"_LANG")
|
||||||
if cookie, error := request.Cookie(name); error == nil {
|
if cookie, error := request.Cookie(name); error == nil {
|
||||||
return true, cookie.Value
|
return true, cookie.GetValue()
|
||||||
} else {
|
} else {
|
||||||
revel.TRACE.Printf("Unable to read locale cookie with name '%s': %s", name, error.Error())
|
revel.TRACE.Printf("Unable to read locale cookie with name '%s': %s", name, error.Error())
|
||||||
}
|
}
|
||||||
|
@ -3,7 +3,7 @@ package route
|
|||||||
import (
|
import (
|
||||||
"github.com/leanote/leanote/app/db"
|
"github.com/leanote/leanote/app/db"
|
||||||
"github.com/revel/revel"
|
"github.com/revel/revel"
|
||||||
// . "github.com/leanote/leanote/app/lea"
|
. "github.com/leanote/leanote/app/lea"
|
||||||
"net/url"
|
"net/url"
|
||||||
"strings"
|
"strings"
|
||||||
)
|
)
|
||||||
@ -14,15 +14,19 @@ var staticPrefix = []string{"/public", "/favicon.ico", "/css", "/js", "/images",
|
|||||||
|
|
||||||
func RouterFilter(c *revel.Controller, fc []revel.Filter) {
|
func RouterFilter(c *revel.Controller, fc []revel.Filter) {
|
||||||
// 补全controller部分
|
// 补全controller部分
|
||||||
path := c.Request.Request.URL.Path
|
path := c.Request.URL.Path
|
||||||
|
|
||||||
// Figure out the Controller/Action
|
// Figure out the Controller/Action
|
||||||
var route *revel.RouteMatch = revel.MainRouter.Route(c.Request.Request)
|
// var route *revel.RouteMatch = revel.MainRouter.Route(c.Request.Request)
|
||||||
|
route := revel.MainRouter.Route(c.Request)
|
||||||
|
|
||||||
if route == nil {
|
if route == nil {
|
||||||
c.Result = c.NotFound("No matching route found: " + c.Request.RequestURI)
|
c.Result = c.NotFound("No matching route found: " + c.Request.GetRequestURI())
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Log("---------" + route.Action + " " + path)
|
||||||
|
|
||||||
// The route may want to explicitly return a 404.
|
// The route may want to explicitly return a 404.
|
||||||
if route.Action == "404" {
|
if route.Action == "404" {
|
||||||
c.Result = c.NotFound("(intentionally)")
|
c.Result = c.NotFound("(intentionally)")
|
||||||
@ -47,14 +51,23 @@ func RouterFilter(c *revel.Controller, fc []revel.Filter) {
|
|||||||
// 检查mongodb 是否lost
|
// 检查mongodb 是否lost
|
||||||
db.CheckMongoSessionLost()
|
db.CheckMongoSessionLost()
|
||||||
|
|
||||||
|
// /api/file/getImage -> App\file (/api/file/getImage)
|
||||||
|
// App\auth
|
||||||
|
// App\note
|
||||||
|
// static\static
|
||||||
|
//
|
||||||
|
// Log("---------" + route.ControllerName + " " + path)
|
||||||
|
|
||||||
// api设置
|
// api设置
|
||||||
// leanote.com/api/user/get => ApiUser::Get
|
// leanote.com/api/user/get => ApiUser::Get
|
||||||
//* /api/login ApiAuth.Login, 这里的设置, 其实已经转成了ApiAuth了
|
//* /api/login ApiAuth.Login, 这里的设置, 其实已经转成了ApiAuth了
|
||||||
if strings.HasPrefix(path, "/api") && !strings.HasPrefix(route.ControllerName, "Api") {
|
if strings.HasPrefix(path, "/api") && !strings.HasPrefix(route.ControllerName, "App\\api") {
|
||||||
route.ControllerName = "Api" + route.ControllerName
|
route.ControllerName = "App\\api" + strings.Split(route.ControllerName, "\\")[1]
|
||||||
} else if strings.HasPrefix(path, "/member") && !strings.HasPrefix(route.ControllerName, "Member") {
|
// route.ControllerName = "App\\apifile"
|
||||||
|
} else if strings.HasPrefix(path, "/member") && !strings.HasPrefix(route.ControllerName, "App\\member") {
|
||||||
// member设置
|
// member设置
|
||||||
route.ControllerName = "Member" + route.ControllerName
|
// route.ControllerName = "App\\Member" + route.ControllerName
|
||||||
|
route.ControllerName = "App\\member" + strings.Split(route.ControllerName, "\\")[1]
|
||||||
}
|
}
|
||||||
// end
|
// end
|
||||||
}
|
}
|
||||||
|
@ -128,6 +128,12 @@ GET /upload/*filepath Static.Serve("public/upload")
|
|||||||
# the prefix of member's controllername is "Member"
|
# the prefix of member's controllername is "Member"
|
||||||
* /member MemberIndex.Index
|
* /member MemberIndex.Index
|
||||||
* /member/index MemberIndex.Index
|
* /member/index MemberIndex.Index
|
||||||
|
* /member/group/index MemberGroup.Index
|
||||||
|
* /member/group/addGroup MemberGroup.AddGroup
|
||||||
|
* /member/group/updateGroupTitle MemberGroup.UpdateGroupTitle
|
||||||
|
* /member/group/deleteGroup MemberGroup.DeleteGroup
|
||||||
|
* /member/group/addUser MemberGroup.AddUser
|
||||||
|
* /member/group/deleteUser MemberGroup.DeleteUser
|
||||||
|
|
||||||
# common
|
# common
|
||||||
* /:controller/:action :controller.:action
|
* /:controller/:action :controller.:action
|
||||||
|
Reference in New Issue
Block a user