ludc
2025-01-16 68fd566d21b3efc3a670a5295289b1801f5a4155
Source/plt-web/plt-web-parent/plt-web/src/main/java/com/vci/web/controller/SmFunctionController.java
@@ -1,6 +1,7 @@
package com.vci.web.controller;
import com.vci.corba.common.PLException;
import com.vci.starter.web.util.VciBaseUtil;
import com.vci.web.service.ISmFunctionQueryService;
import com.vci.web.enumpck.ResourceControlTypeEnum;
import com.vci.pagemodel.MenuVO;
@@ -47,14 +48,31 @@
   }
   /**
    * 获取当前用户的所有按钮
    * @param treeQueryObject 树查询对象
    * @return
    */
   @GetMapping("/getAllButtons")
   public BaseResult getAllButtons(TreeQueryObject treeQueryObject){
      return BaseResult.dataList(functionQueryService.buttons(treeQueryObject));
   }
   /**
    * 获取当前用户的菜单
    * @param treeQueryObject 树查询对象
    * @return  树节点,出现错误会在异常处理器中统一返回Json
    */
   @VciUnCheckRight
   @GetMapping("/getUIContentByBtmTypeAndId")
   public UIContentVO getUIContentByBtmTypeAndId(@RequestBody TreeQueryObject treeQueryObject) throws PLException {
      return functionQueryService.getUIContentByBtmTypeAndId(treeQueryObject, ResourceControlTypeEnum.BS);
   public BaseResult getUIContentByBtmTypeAndId(@RequestBody TreeQueryObject treeQueryObject) {
      try {
         return BaseResult.success(functionQueryService.getUIContentByBtmTypeAndId(treeQueryObject, ResourceControlTypeEnum.BS));
      } catch (Exception e) {
         e.printStackTrace();
         String exceptionMessage = "获取当前用户的菜单时出现错误,原因:" + VciBaseUtil.getExceptionMessage(e);
         logger.error(exceptionMessage);
         return BaseResult.fail(exceptionMessage);
      }
   }
   
   /**