09 2019 档案

摘要:基本操作01: 获取当前时间dateTime := time.Now()fmt.Println(dateTime)02: 获取年 月 日 时 分 秒 纳秒year := time.Now().Year() //年fmt.Println(year)month := time.Now().Month() 阅读全文
posted @ 2019-09-21 21:58 风一样自由419154 阅读(186) 评论(0) 推荐(0) 编辑
摘要:package mainimport ( "database/sql" "encoding/json" "fmt" "github.com/gogf/gf/encoding/gjson" "github.com/gogf/gf/frame/g" "github.com/gogf/gf/os/glog 阅读全文
posted @ 2019-09-21 21:17 风一样自由419154 阅读(637) 评论(0) 推荐(0) 编辑
摘要:结构体生成Json ?123456789101112131415161718192021222324252627282930package main import ( "encoding/json" "fmt") type IT struct { Company string `json:"-"` 阅读全文
posted @ 2019-09-21 18:51 风一样自由419154 阅读(719) 评论(0) 推荐(0) 编辑
摘要:package mainimport "fmt"func main9() { // 可以打印各种格式,打印时自带换行 // fmt.Println(22) // 可以打印各种格式,打印时不带换行 // fmt.Print(11) // 整型 // 占位符,打印时不带换行 fmt.Printf("== 阅读全文
posted @ 2019-09-10 08:36 风一样自由419154 阅读(363) 评论(0) 推荐(0) 编辑