system.go 614 Bytes
Newer Older
qiuqunfeng's avatar
qiuqunfeng committed
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28
package controller

import (
	"time"

	"github.com/gin-gonic/gin"
)

type SystemController struct {
	// service service.Service
	// controller.Api
}

func NewSystemController() *SystemController {
	return &SystemController{
		// service: service.NewI pService(config.WeibuUrl, apiKey),
	}
}

func (c *SystemController) SystemInfo(ctx *gin.Context) {
	ctx.JSON(200, gin.H{
		"model":          "B7b-xxx",
		"description":    "test",
		"latestLearning": time.Now().UnixMilli(),
		"learningPeriod": time.Duration(time.Hour + time.Minute*12 + time.Second*11).String(),
		"modelTime":      time.Now().UnixMilli(),
	})
}