mirror of
https://github.com/crawlab-team/crawlab.git
synced 2026-01-22 17:31:03 +01:00
- Refactored multiple controller methods to accept structured parameters for improved clarity and maintainability. - Consolidated error handling and response generation across various endpoints. - Updated function signatures to eliminate unnecessary context parameters and enhance type safety. - Improved consistency in response formatting and error handling across controllers. - Enhanced file handling methods to support multipart file uploads and directory operations more effectively.
16 lines
367 B
Go
16 lines
367 B
Go
package controllers
|
|
|
|
import (
|
|
"github.com/crawlab-team/crawlab/core/entity"
|
|
"github.com/crawlab-team/crawlab/core/utils"
|
|
"github.com/gin-gonic/gin"
|
|
)
|
|
|
|
func GetSystemInfo(c *gin.Context) (response *Response[entity.SystemInfo], err error) {
|
|
info := entity.SystemInfo{
|
|
Edition: utils.GetEdition(),
|
|
Version: utils.GetVersion(),
|
|
}
|
|
return GetDataResponse(info)
|
|
}
|