Helius
2021-03-18 605ad677377b5aa3e163890ef3ca43df49f57e67
zq-erp/src/main/java/com/matrix/system/common/init/InitWebContainer.java
@@ -14,6 +14,9 @@
import com.matrix.system.common.service.SysCompanyService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.context.event.ContextRefreshedEvent;
import org.springframework.context.event.EventListener;
import org.springframework.stereotype.Component;
import org.springframework.stereotype.Controller;
import org.springframework.web.context.ServletContextAware;
@@ -25,8 +28,8 @@
 * @author:姜友瑶
 * @date 2016年10月18日
 */
@Controller
public class InitWebContainer   implements ServletContextAware{
@Component
public class InitWebContainer implements ServletContextAware{
   private static final String TRUE = "true";
@@ -62,7 +65,6 @@
   @Override
   public void setServletContext(ServletContext sc) {
      this.servletContext = sc;
      // 初始化调试模式
      initDebug();
      // 初始化语言环境
@@ -70,13 +72,18 @@
      //初始化公司
      initParams();
      LogUtil.info("\r\n\r\n**********************************************\r\n"
            + "* =========== Matrix启动成功 ===========\r\n"
            + "* =========== Matrix启动成功 ===========\r\n"
            + "* DEBUG模式:" + debug+"*\r\n"
            + "* 语言环境:" + Locale.getDefault().getLanguage()+"\r\n"
            + "**********************************************\r\n");
   }
//   @EventListener
//   public void onApplicationEvent(ContextRefreshedEvent event) {
//
//   }
   private void initDebug() {
      if (TRUE.equals(debug)) {
         MatrixConstance.DEBUG = true;