18 lines
361 B
Go
18 lines
361 B
Go
|
package controllers
|
||
|
|
||
|
import (
|
||
|
"github.com/HFO4/cloudreve/service/admin"
|
||
|
"github.com/gin-gonic/gin"
|
||
|
)
|
||
|
|
||
|
// AdminSummary 获取管理站点概况
|
||
|
func AdminSummary(c *gin.Context) {
|
||
|
var service admin.NoParamService
|
||
|
if err := c.ShouldBindUri(&service); err == nil {
|
||
|
res := service.Summary()
|
||
|
c.JSON(200, res)
|
||
|
} else {
|
||
|
c.JSON(200, ErrorResponse(err))
|
||
|
}
|
||
|
}
|