이용내역 권한 관련

This commit is contained in:
focp212@naver.com
2025-11-05 15:26:14 +09:00
parent ad28ccd82f
commit fb889a9f2c
14 changed files with 119 additions and 102 deletions

View File

@@ -0,0 +1,10 @@
import { useStore } from "../model/store";
export const checkGrant = (menuId?: number, authType: string = 'R') => {
const menuGrantsByKey = useStore.getState().UserStore.menuGrantsByKey;
const myGrants = menuGrantsByKey['' + menuId];
if(myGrants?.includes(authType) || menuId === -1){
return true
}
return false;
};