diff --git a/server/adminserver/api/v1/system/giftcode.go b/server/adminserver/api/v1/system/giftcode.go index 0a7dc3af..e7a432a2 100644 --- a/server/adminserver/api/v1/system/giftcode.go +++ b/server/adminserver/api/v1/system/giftcode.go @@ -303,7 +303,7 @@ func (gca *GiftCodeApi) QueryCode(c *gin.Context) { Type int32 `json:"type"` }{} codeinfo := new(system.GiftCode) - db := f5.GetApp().GetOrmDb(constant.ACCOUNT_DB).Table(codeinfo.TableName()).Take(codeinfo, "gameid = ? AND gift_code = '?'", req.GameId, req.Code) + db := f5.GetApp().GetOrmDb(constant.ACCOUNT_DB).Table(codeinfo.TableName()).Take(codeinfo, "gameid = ? AND gift_code = ?", req.GameId, req.Code) err := db.Error if err != nil { if !f5.IsOrmErrRecordNotFound(err) {