com.github.happyjiahui.z.web.controller.BaseController Maven / Gradle / Ivy
package com.github.happyjiahui.z.web.controller;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import javax.validation.ValidationException;
import org.springframework.validation.BindingResult;
import org.springframework.validation.FieldError;
import com.alibaba.fastjson.JSON;
/**
* controller基类,提供参数校验等功能。
*
* @author zhaojinbing
* @version 0.1
*/
public class BaseController {
/**
* 校验参数
*
* @param result
* {@link BindingResult}
*/
protected void checkBindingResult(BindingResult result) {
if (result.hasErrors()) {
List
© 2015 - 2024 Weber Informatics LLC | Privacy Policy