<template>
    <ul class="menu">
      <li class="nav-item">
        <router-link to="/approval-management.page" class="nav-link " active-class="active">
          <span>결재관리</span></router-link>
      </li><!-- End Dashboard Nav -->
      <i class="fa-solid fa-bars"></i>

      <li class="nav-item">
        <router-link to="/attendance-management.page" class="nav-link " active-class="active">
          <span>근태관리</span></router-link>
      </li>
      <i class="fas fa-bars"></i>
      <li class="nav-item">
        <router-link to="/task-management.page" class="nav-link " active-class="active">
          <span>업무관리</span></router-link>
      </li>
      <i class="fas fa-bars"></i>
      <li class="nav-item">
        <router-link to="/financial-management.page" class="nav-link " active-class="active">
          <span>재무관리</span></router-link>
      </li>
      <i class="fas fa-bars"></i>
      <li class="nav-item">
        <router-link to="/asset-management.page" class="nav-link " active-class="active">
          <span>자산관리</span></router-link>
      </li><!-- End Register Page Nav -->
      <i class="fas fa-bars"></i>
      <li class="nav-item">
        <router-link to="/hr-management.page" class="nav-link " active-class="active">
          <span>인사관리</span></router-link>
      </li><!-- End Login Page Nav -->
      <i class="fas fa-bars"></i>
      <li class="nav-item">
        <router-link to="/system-management.page" class="nav-link " active-class="active">
          <span>시스템관리</span></router-link>
      </li>


    </ul><!-- End Profile Dropdown Items -->

</template>

<script>
export default {
  name: "ProfileImage",
  data() {
    return {
      isLoggedIn: false,
      userName: '',
      logo: "/client/resources/img/logo.png",
    };
  },
  methods: {
    handleLogout() {
      // Clear login-related data from localStorage
      localStorage.removeItem('loggedInUser');
      this.isLoggedIn = false; // Update login status
      this.$router.push("/login"); // Redirect to login page after logout
    },
    toggleSidebar() {
      // `toggle-sidebar` 클래스가 있으면 제거, 없으면 추가
      document.body.classList.toggle("toggle-sidebar");
    },
  },
  created() {
    // Check if there is any login data in localStorage
    const loggedInUser = localStorage.getItem('loggedInUser');
    if (loggedInUser) {
      this.isLoggedIn = true;
    }
  },
  components: {
  },
};
</script>

<style></style>