Jelajahi Sumber

修改授权标识,解开验证码

阿伏兔 4 tahun lalu
induk
melakukan
837f99fbc7

+ 1 - 1
ruoyi-admin/src/main/java/com/ruoyi/web/controller/warehouse/agreement/TWarehouseAgreementitemsController.java

@@ -30,7 +30,7 @@ public class TWarehouseAgreementitemsController extends BaseController {
     /**
      * 查询仓储费明细表列表
      */
-    @PreAuthorize("@ss.hasPermi('warehouseBusiness:agreementitems:list')")
+//    @PreAuthorize("@ss.hasPermi('warehouseBusiness:agreementitems:list')")
     @GetMapping("/list")
     public TableDataInfo list(TWarehouseAgreementitems tWarehouseAgreementitems) {
         startPage();

+ 1 - 1
ruoyi-admin/src/main/java/com/ruoyi/web/controller/warehouse/approvalFlow/AuditPathsController.java

@@ -127,7 +127,7 @@ public class AuditPathsController extends BaseController {
     /**
      * 根据id、actId 查询审批流
      */
-    @PreAuthorize("@ss.hasPermi('warehouse:paths:query')")
+//    @PreAuthorize("@ss.hasPermi('warehouse:paths:query')")
     @PostMapping(value = "/projectEndQueryPendingVal")
     public AjaxResult projectEndQueryPendingVal(@RequestBody AuditItems auditItems) {
         if (StringUtils.isNull(auditItems) || StringUtils.isNull(auditItems.getId()) || StringUtils.isNull(auditItems.getActId())) {

+ 10 - 8
ruoyi-framework/src/main/java/com/ruoyi/framework/web/service/SysLoginService.java

@@ -4,6 +4,8 @@ import com.ruoyi.common.constant.Constants;
 import com.ruoyi.common.core.domain.model.LoginUser;
 import com.ruoyi.common.core.redis.RedisCache;
 import com.ruoyi.common.exception.CustomException;
+import com.ruoyi.common.exception.user.CaptchaException;
+import com.ruoyi.common.exception.user.CaptchaExpireException;
 import com.ruoyi.common.exception.user.UserPasswordNotMatchException;
 import com.ruoyi.common.utils.MessageUtils;
 import com.ruoyi.framework.manager.AsyncManager;
@@ -46,14 +48,14 @@ public class SysLoginService {
         String verifyKey = Constants.CAPTCHA_CODE_KEY + uuid;
         String captcha = redisCache.getCacheObject(verifyKey);
         redisCache.deleteObject(verifyKey);
-//        if (captcha == null) {
-//            AsyncManager.me().execute(AsyncFactory.recordLogininfor(username, Constants.LOGIN_FAIL, MessageUtils.message("user.jcaptcha.expire")));
-//            throw new CaptchaExpireException();
-//        }
-//        if (!code.equalsIgnoreCase(captcha)) {
-//            AsyncManager.me().execute(AsyncFactory.recordLogininfor(username, Constants.LOGIN_FAIL, MessageUtils.message("user.jcaptcha.error")));
-//            throw new CaptchaException();
-//        }
+        if (captcha == null) {
+            AsyncManager.me().execute(AsyncFactory.recordLogininfor(username, Constants.LOGIN_FAIL, MessageUtils.message("user.jcaptcha.expire")));
+            throw new CaptchaExpireException();
+        }
+        if (!code.equalsIgnoreCase(captcha)) {
+            AsyncManager.me().execute(AsyncFactory.recordLogininfor(username, Constants.LOGIN_FAIL, MessageUtils.message("user.jcaptcha.error")));
+            throw new CaptchaException();
+        }
         // 用户验证
         Authentication authentication = null;
         try {

+ 2 - 0
ruoyi-warehouse/src/main/resources/mapper/warehouseBusiness/TWarehouseAgreementitemsMapper.xml

@@ -110,11 +110,13 @@
             AND items.f_feeUnitid = #{feeUnitid}
             AND agreement.f_status = 1
             AND agreement.del_flag = '0'
+            AND agreement.f_feetypeid = '0'
             AND items.del_flag = '0'
             AND items.f_status = 'T'
         ORDER BY
             items.f_fromdays
     </select>
+
     <select id="selectTWarehouseAgreementitemsList1" resultType="java.util.Map">
         SELECT DISTINCT
             agre.f_id AS fId,