<mat-accordion>
    <mat-expansion-panel [expanded]=true>
        <mat-expansion-panel-header>
            <mat-panel-title>
                Baskets
            </mat-panel-title>
            <mat-panel-description>
                <mat-icon>shopping-basket</mat-icon>
            </mat-panel-description>
        </mat-expansion-panel-header>
        <mat-list-item *ngFor="let basket of baskets">
            <button mat-button
                    matTooltip="{{ basket['name'] }}"
                    routerLink="/admin/basket/{{ basket['name'] }}"
                    routerLinkActive="active"
                    >
                {{ basket['name'] }}
            </button>
        </mat-list-item>
    </mat-expansion-panel>

    <mat-expansion-panel>
        <mat-expansion-panel-header>
            <mat-panel-title>
                Survey
            </mat-panel-title>
            <mat-panel-description>
                <mat-icon>gps_fixed</mat-icon>
            </mat-panel-description>
        </mat-expansion-panel-header>
        <mat-list-item>
            <button mat-button
                    routerLink="/admin/survey/categories"
                    routerLinkActive="active"
                >
                Categories
            </button>
        </mat-list-item>
    </mat-expansion-panel>

    <mat-expansion-panel>
        <mat-expansion-panel-header>
            <mat-panel-title>
                Scheduler
            </mat-panel-title>
            <mat-panel-description>
                <mat-icon>alarm</mat-icon>
            </mat-panel-description>
        </mat-expansion-panel-header>
        <mat-list-item>
            <button mat-button
                    routerLink="/admin/scheduler/jobs"
                    routerLinkActive="active"
                >
                Jobs
            </button>
        </mat-list-item>
        <mat-list-item>
            <button mat-button
                    routerLink="/admin/scheduler/messages"
                    routerLinkActive="active"
                >
                Messages
            </button>
        </mat-list-item>
    </mat-expansion-panel>

    <mat-expansion-panel
        *ngIf="authenticationService.isAuthorized(['manager']) | async"
        >
        <mat-expansion-panel-header>
            <mat-panel-title>
                Manage
            </mat-panel-title>
            <mat-panel-description>
                <mat-icon>settings</mat-icon>
            </mat-panel-description>
        </mat-expansion-panel-header>

        <mat-list-item>
            <button mat-button
                    routerLink="/admin/manage/projects"
                    routerLinkActive="active"
                >
                Projects
            </button>
        </mat-list-item>

        <mat-list-item class='root'
            *ngIf="authenticationService.isAuthorized(['manager']) | async"
        >
            <button mat-button
                    routerLink="/admin/manage/access"
                    routerLinkActive="active"
                >
                Access
            </button>
        </mat-list-item>

        <mat-list-item>
            <button mat-button
                    routerLink="/admin/manage/integrity"
                    routerLinkActive="active"
                >
                Integrity
            </button>
        </mat-list-item>

        <mat-list-item>
            <button mat-button
                    routerLink="/admin/manage/maintenance"
                    routerLinkActive="active"
                >
                Maintenance
            </button>
        </mat-list-item>

        <mat-list-item>
            <button mat-button
                    routerLink="/admin/manage/points-by-orig-id"
                    routerLinkActive="active"
                >
                Points by orig. ID
            </button>
        </mat-list-item>

    </mat-expansion-panel>

    <!-- Models are currently disabled, need fixes
    <mat-expansion-panel [disabled]=true>
        <mat-expansion-panel-header>
            <mat-panel-title>
                Models
            </mat-panel-title>
        </mat-expansion-panel-header>
    </mat-expansion-panel>

    <mat-expansion-panel
        *ngFor="let menuItem of adminModelsMenuItems"
        >
        <mat-expansion-panel-header>
            <mat-panel-title>
                {{ menuItem['name'] }}
            </mat-panel-title>
        </mat-expansion-panel-header>
        <mat-list-item
            *ngFor="let item of menuItem['items']"
            >
            <button mat-button
                    matTooltip="{{ item['name'] }}"
                    routerLink="/admin/model/{{ item['name'] }}"
                    routerLinkActive="active"
                    >
                {{ item['name'] }}
            </button>
        </mat-list-item>
    </mat-expansion-panel>
    -->
</mat-accordion>
