From 381fd3d720fbc1740056618260e7229ad5139ead Mon Sep 17 00:00:00 2001 From: junleea <354425203@qq.com> Date: Fri, 27 Dec 2024 19:37:19 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0file=E8=A1=A8=E6=95=B0?= =?UTF-8?q?=E6=8D=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- dao/file.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dao/file.go b/dao/file.go index 06ffc79..058a832 100644 --- a/dao/file.go +++ b/dao/file.go @@ -5,7 +5,7 @@ import "gorm.io/gorm" type File struct { gorm.Model // 存储文件名 - FileStoreName string `gorm:"column:file_store_name;uniqueIndex:idx_file_name"` + FileStoreName string `gorm:"column:file_store_name;type:varchar(255);uniqueIndex:idx_file_name"` NeedAuth bool `gorm:"column:need_auth"` FileName string `gorm:"column:file_name"` FileSize int `gorm:"column:file_size"`