修改参数验证,统一返回200

This commit is contained in:
linwenxiang committed 2020-09-24 21:47:48 +08:00
1 parent 7e2e40df56
commit 677cdb7821
2 files changed
+5 -5

No files matched your search

+2 -2
View File
@@ -24,7 +24,7 @@ func (m *SysJobSearch) GetNeedSearch() interface{} {
}
func (m *SysJobSearch) Bind(ctx *gin.Context) error {
err := ctx.Bind(m)
err := ctx.ShouldBind(m)
if err != nil {
log.Errorf("MsgID[%s] Bind error: %s", err)
}
@@ -51,7 +51,7 @@ type SysJobControl struct {
}
func (s *SysJobControl) Bind(ctx *gin.Context) error {
return ctx.Bind(s)
return ctx.ShouldBind(s)
}
func (s *SysJobControl) Generate() dto.Control {