79614b2d07
- Updated multiple repository and service files to replace imports from "github.com/mlogclub/simple/web/params" with "cs-agent/internal/pkg/httpx/params". - Adjusted context handling in auth_service and ws_service to use gin.Context instead of iris.Context. - Ensured consistent usage of HTTP status responses across websocket handlers.
19 lines
398 B
Go
19 lines
398 B
Go
package dashboard
|
|
|
|
import (
|
|
"cs-agent/internal/services"
|
|
|
|
"cs-agent/internal/pkg/httpx/params"
|
|
"github.com/gin-gonic/gin"
|
|
"github.com/mlogclub/simple/web"
|
|
)
|
|
|
|
type DashboardController struct {
|
|
Ctx *gin.Context
|
|
}
|
|
|
|
func (c *DashboardController) GetOverview() *web.JsonResult {
|
|
rangeValue, _ := params.Get(c.Ctx, "range")
|
|
return web.JsonData(services.DashboardService.GetOverview(rangeValue))
|
|
}
|