036c0a2d by chentao

no message

1 parent a0d2f4d1
......@@ -186,7 +186,8 @@ public class GlobalExceptionHandler {
@ExceptionHandler(MethodArgumentNotValidException.class)
public R<Void> handleMethodArgumentNotValidException(MethodArgumentNotValidException e) {
System.out.println("=============="+e.getMessage());
log.error(e.getMessage());
log.error(e.getBindingResult().getObjectName());
log.error(e.getBindingResult().getFieldError().getField());
String message = e.getBindingResult().getFieldError().getDefaultMessage();
return R.fail(message);
}
......
Styling with Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!