go-gallery/routers/album/photo.go
2018-04-30 10:13:01 +08:00

26 lines
445 B
Go

package album
import (
"git.trj.tw/golang/go-gallery/models"
"git.trj.tw/golang/go-gallery/modules/context"
)
// GetAllAlbumPhotos -
func GetAllAlbumPhotos(c *context.Context) {
}
// GetPhoto -
func GetPhoto(c *context.Context) {
album, ok := c.Get("album")
if !ok {
c.NotFound("album not found")
return
}
_, err := models.GetPhoto(album.(map[string]interface{})["id"].(string))
if err != nil {
c.ServerError(nil)
return
}
}