E1ED922C1E9526DD63272D7EC5C6CB77
2021-04-16 b7ab9f397ef2322fa0e79ab51fc16cbd77399835
src/main/java/com/hx/common/BaseController.java
@@ -1,5 +1,6 @@
package com.hx.common;
import com.hx.common.service.CommonService;
import com.hx.exception.ParamException;
import com.hx.exception.ServiceException;
import org.springframework.beans.propertyeditors.CustomDateEditor;
@@ -9,6 +10,7 @@
import org.springframework.web.context.request.ServletRequestAttributes;
import org.springframework.web.context.request.WebRequest;
import javax.annotation.Resource;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpSession;
import java.text.DateFormat;
@@ -23,6 +25,9 @@
public class BaseController {
   @Resource
   protected CommonService commonService;
   /*请不要声明变量,会导致不安全,因为这个是单列*/
   //只需要加上下面这段即可,注意不能忘记注解