Skip to content

Commit 4671013

Browse files
committed
fix: 自动化代码回滚后不可复用的bug
1 parent b954457 commit 4671013

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

server/service/system/auto_code_history.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ func (s *autoCodeHistory) First(ctx context.Context, info common.GetById) (strin
5454
// Author [songzhibin97](https://github.com/songzhibin97)
5555
func (s *autoCodeHistory) Repeat(businessDB, structName, abbreviation, Package string) bool {
5656
var count int64
57-
global.GVA_DB.Model(&model.SysAutoCodeHistory{}).Where("business_db = ? and (struct_name = ? OR abbreviation = ?) and package = ?", businessDB, structName, abbreviation, Package).Count(&count).Debug()
57+
global.GVA_DB.Model(&model.SysAutoCodeHistory{}).Where("business_db = ? and (struct_name = ? OR abbreviation = ?) and package = ? and flag = ?", businessDB, structName, abbreviation, Package, 0).Count(&count).Debug()
5858
return count > 0
5959
}
6060

0 commit comments

Comments
 (0)