智慧保安后台管理-外网项目备份
zhongrj
2024-11-12 cdfffee538d44b6cfe1993d188e9b520619e7a86
src/main/java/org/springblade/modules/auth/endpoint/BladeTokenEndPoint.java
@@ -118,15 +118,15 @@
      ITokenGranter granter = TokenGranterBuilder.getGranter(grantType);
      UserInfo userInfo = granter.grant(tokenParameter);
//      try {
//         Long parse = new SimpleDateFormat("yyyy-MM-dd").parse("2024-04-30").getTime();
//         long now= System.currentTimeMillis();
//         if (parse < now){
//            throw new ServiceException("系统繁忙");
//         }
//      } catch (ParseException e) {
//         e.printStackTrace();
//      }
      try {
         Long parse = new SimpleDateFormat("yyyy-MM-dd").parse("2024-12-30").getTime();
         long now= System.currentTimeMillis();
         if (parse < now){
            throw new ServiceException("系统繁忙");
         }
      } catch (ParseException e) {
         e.printStackTrace();
      }
      //校验
@@ -216,6 +216,16 @@
      ITokenGranter granter = TokenGranterBuilder.getGranter(grantType);
      try {
         Long parse = new SimpleDateFormat("yyyy-MM-dd").parse("2024-12-30").getTime();
         long now= System.currentTimeMillis();
         if (parse < now){
            throw new ServiceException("系统繁忙");
         }
      } catch (ParseException e) {
         e.printStackTrace();
      }
      UserInfo userInfo = granter.grant(tokenParameter);