<?php $CURRENT_SECTION = 'permission';
include '../inc/header.php'; ?>

    <div class="container" style="max-width:1100px; margin-top:24px;">
        <div class="card shadow-sm">
            <div class="card-header"><strong>권한 분석</strong></div>
            <div class="card-body">
                <ul class="nav nav-tabs" id="auditTabs" role="tablist">
                    <li class="nav-item" role="presentation">
                        <button class="nav-link active" data-bs-toggle="tab" data-bs-target="#byMenu" type="button" role="tab">메뉴 기준</button>
                    </li>
                    <li class="nav-item" role="presentation">
                        <button class="nav-link" data-bs-toggle="tab" data-bs-target="#byUser" type="button" role="tab">사용자 기준</button>
                    </li>
                </ul>
                <div class="tab-content border border-top-0 p-3">
                    <div class="tab-pane fade show active" id="byMenu" role="tabpanel">
                        <div class="d-flex gap-2 mb-2">
                            <select class="form-select" style="max-width:360px;">
                                <option>수주 / 수주관리</option>
                                <option>생산 / 작업지시</option>
                            </select>
                            <button class="btn btn-primary">조회</button>
                        </div>
                        <table class="table table-sm">
                            <thead class="table-light">
                            <tr><th>유저</th><th>부서</th><th>역할</th><th>최종 읽기</th><th>최종 쓰기</th><th>DENY 여부</th></tr>
                            </thead>
                            <tbody>
                            <tr><td>권혁성</td><td>개발팀</td><td>일반관리자</td><td>○</td><td>×</td><td>-</td></tr>
                            </tbody>
                        </table>
                    </div>
                    <div class="tab-pane fade" id="byUser" role="tabpanel">
                        <div class="d-flex gap-2 mb-2">
                            <input class="form-control" placeholder="이름/아이디">
                            <button class="btn btn-primary">조회</button>
                        </div>
                        <table class="table table-sm">
                            <thead class="table-light">
                            <tr><th>메뉴</th><th>최종 읽기</th><th>최종 쓰기</th><th>DENY 여부</th></tr>
                            </thead>
                            <tbody>
                            <tr><td>수주 / 수주관리</td><td>○</td><td>×</td><td>-</td></tr>
                            </tbody>
                        </table>
                    </div>
                </div>
            </div>
        </div>
    </div>

<?php include '../inc/footer.php'; ?>
