|
|
@ -114,6 +114,9 @@ func (impl *ArtCheckRuleServiceImplement) InsertOne(user *global.User, entity *m |
|
|
|
if recordAttribute == nil { |
|
|
|
return grmi.NewBusinessError("不存在指定零件属性!") |
|
|
|
} |
|
|
|
if entity.CodeLength == "" { |
|
|
|
entity.CodeLength = "可变" |
|
|
|
} |
|
|
|
err = dao.InsertOne(entity) |
|
|
|
if err != nil { |
|
|
|
return err |
|
|
@ -198,6 +201,9 @@ func (impl *ArtCheckRuleServiceImplement) UpdateOne(user *global.User, entity *m |
|
|
|
return grmi.NewBusinessError("不存在指定零件属性") |
|
|
|
} |
|
|
|
} |
|
|
|
if entity.CodeLength == "" { |
|
|
|
entity.CodeLength = "可变" |
|
|
|
} |
|
|
|
err = dao.UpdateOne(entity) |
|
|
|
if err != nil { |
|
|
|
return err |
|
|
|