lyh
2025-04-22 4442d11ce67ae83fedac69c177b7f49c0a7e3d94
src/utils/authFilter.js
@@ -238,6 +238,32 @@
}
/**
 * 显示权限
 * @param {*} code
 * @returns
 */
export function buttonShowAuthFilter(code) {
  if(code){
    if(nodeShowAuth(code)){
      return true;
    }else{
      return false;
    }
  }else{
    return false;
  }
}
function nodeShowAuth(code){
  let authList = JSON.parse(sessionStorage.getItem(USER_AUTH) || "[]");
  for (let auth of authList) {
    if(auth.action == code) {
      return true;
    }
  }
  return false;
}
/**
 * 额外增加方法【用于行编辑组件】