From 738babf6c255e55f8880834d620d140dbd75a8a0 Mon Sep 17 00:00:00 2001 From: tianjun Date: Fri, 3 Feb 2023 10:27:04 +0800 Subject: [PATCH] ei... --- main.go | 32 +++++++++++++++----------------- 1 file changed, 15 insertions(+), 17 deletions(-) diff --git a/main.go b/main.go index ab65a7a..812d63f 100644 --- a/main.go +++ b/main.go @@ -2,7 +2,6 @@ package main // init函数执行顺序自上而下, 最后执行main包里面的init函数 import ( - "cutego/modules/core/dataobject" "cutego/pkg/config" _ "cutego/pkg/cronjob" _ "cutego/pkg/gin" @@ -11,26 +10,25 @@ import ( "cutego/refs" "fmt" "github.com/gin-gonic/gin" - "time" ) func main() { //go testChangeJob() - //starter() - user := dataobject.SysUser{} - user.UserId = 1 - user.UserName = "test" - user.Password = "123456" - user.LoginDate = time.Now() - jsonString := util.ToJSONString(user) - fmt.Println(jsonString) - fmt.Println(util.FormatDateTime(user.LoginDate)) - fmt.Println(util.FormatDate(user.LoginDate)) - fmt.Println(util.FormatTime(user.LoginDate)) - - sysUser := dataobject.SysUser{} - util.ParseJSONStruct(jsonString, &sysUser) - fmt.Println(sysUser) + starter() + //user := dataobject.SysUser{} + //user.UserId = 1 + //user.UserName = "test" + //user.Password = "123456" + //user.LoginDate = time.Now() + //jsonString := util.ToJSONString(user) + //fmt.Println(jsonString) + //fmt.Println(util.FormatDateTime(user.LoginDate)) + //fmt.Println(util.FormatDate(user.LoginDate)) + //fmt.Println(util.FormatTime(user.LoginDate)) + // + //sysUser := dataobject.SysUser{} + //util.ParseJSONStruct(jsonString, &sysUser) + //fmt.Println(sysUser) } func starter() {