数据类型:GORM自定义数据类型集合

时间:2021-02-03 21:07:16
【文件属性】:
文件名称:数据类型:GORM自定义数据类型集合
文件大小:19KB
文件格式:ZIP
更新时间:2021-02-03 21:07:16
json JSONGo GORM数据类型 JSON格式 sqlite,mysql,postgres支持 import "gorm.io/datatypes" type UserWithJSON struct { gorm. Model Name string Attributes datatypes. JSON } DB. Create ( & User { Name : "json-1" , Attributes : datatypes . JSON ([] byte ( `{"name": "jinzhu", "age": 18, "tags": ["tag1", "tag2"]
【文件预览】:
datatypes-master
----json_test.go(3KB)
----date.go(869B)
----json_map.go(2KB)
----main_test.go(2KB)
----.github()
--------dependabot.yml(528B)
--------workflows()
----License(1KB)
----date_test.go(2KB)
----test_all.sh(256B)
----json_map_test.go(5KB)
----go.sum(18KB)
----json.go(4KB)
----README.md(2KB)
----go.mod(224B)

网友评论