<!DOCTYPE html>
<html lang="en">

<head>

    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no" />
    <title>User - Account - CORASS</title>
    <link rel="icon" href="img/kp.png" type="image/png">

    <link rel="stylesheet" href="css/bootstrap1.min.css" />

    <link rel="stylesheet" href="vendors/themefy_icon/themify-icons.css" />

    <link rel="stylesheet" href="vendors/niceselect/css/nice-select.css" />

    <link rel="stylesheet" href="vendors/owl_carousel/css/owl.carousel.css" />

    <link rel="stylesheet" href="vendors/gijgo/gijgo.min.css" />

    <link rel="stylesheet" href="vendors/font_awesome/css/all.min.css" />
    <link rel="stylesheet" href="vendors/tagsinput/tagsinput.css" />

    <link rel="stylesheet" href="vendors/datepicker/date-picker.css" />

    <link rel="stylesheet" href="vendors/scroll/scrollable.css" />

    <link rel="stylesheet" href="vendors/datatable/css/jquery.dataTables.min.css" />
    <link rel="stylesheet" href="vendors/datatable/css/responsive.dataTables.min.css" />
    <link rel="stylesheet" href="vendors/datatable/css/buttons.dataTables.min.css" />

    <link rel="stylesheet" href="vendors/text_editor/summernote-bs4.css" />

    <link rel="stylesheet" href="vendors/morris/morris.css">

    <link rel="stylesheet" href="vendors/material_icon/material-icons.css" />

    <link rel="stylesheet" href="css/metisMenu.css">

    <link rel="stylesheet" href="css/style1.css" />
    <link rel="stylesheet" href="css/colors/default.css" id="colorSkinCSS">
    <!-- toastr -->
    <link href="js/toastr.css" rel="stylesheet">
</head>

<body class="crm_body_bg">

    <%if(userType=="staff" ){%>
        <%- include('../component/staff-sidebar.ejs')%>
            <%}else{%>
                <%- include('../component/student-sidebar.ejs')%>
                    <%}%>
                        <section class="main_content dashboard_part large_header_bg">

                            <%if(userType=="staff" ){%>
                                <%- include('../component/staff-profile-info.ejs')%>
                                    <%}else{%>
                                        <%- include('../component/student-profile-info.ejs')%>
                                            <%}%>



                                                <div class="modal" id="editUser" tabindex="" aria-hidden="">
                                                    <div
                                                        class="modal-dialog modal-lg modal-dialog-centered modal-edit-user">
                                                        <div class="modal-content">
                                                            <div class="modal-header ">
                                                                <button type="button" class="btn-close"
                                                                    data-bs-dismiss="modal" aria-label="Close"></button>
                                                            </div>
                                                            <div class="modal-body pb-5 px-sm-5 pt-50">
                                                                <div class="text-center mb-2">
                                                                    <h1 class="mb-1">Edit User Information</h1>
                                                                    <p>Updating user details will receive a privacy
                                                                        audit.</p>
                                                                </div>
                                                                <div class="col-12 col-md-6">
                                                                    <label class="form-label"
                                                                        for="lastname">Surname</label>
                                                                    <input type="text" id="lastname" name="lastname"
                                                                        class="form-control"
                                                                        placeholder="Enter your last name"
                                                                        value="<%=profile.lastname%>"
                                                                        data-msg="Please enter your last name" />
                                                                </div>
                                                                <div class="col-12 col-md-6">
                                                                    <label class="form-label" for="firstname">First
                                                                        Name</label>
                                                                    <input type="text" id="firstname" name="firstname"
                                                                        class="form-control"
                                                                        placeholder="Enter your first name"
                                                                        value="<%=profile.firstname%>"
                                                                        data-msg="Please enter your first name" />
                                                                    <input type="hidden" id="user_id" name="user_id"
                                                                        class="form-control" readonly
                                                                        placeholder="Enter your first name"
                                                                        value="<%=user?.id%>"
                                                                        data-msg="Please enter your first name" />
                                                                </div>
                                                                <div class="col-12 col-md-6">
                                                                    <label class="form-label" for="middlename">Middle
                                                                        Name</label>
                                                                    <input type="text" id="middlename" name="middlename"
                                                                        class="form-control"
                                                                        placeholder="Enter your middle name"
                                                                        value="<%=profile.middlename%>"
                                                                        data-msg="Please enter your middle name" />
                                                                </div>
                                                                <div class="col-12 col-md-6">
                                                                    <label class="form-label" for="email">Email</label>
                                                                    <input type="text" id="email" name="email"
                                                                        class="form-control"
                                                                        value="<%=profile.use?.email%>"
                                                                        placeholder="enter your email" />
                                                                </div>
                                                                <div class="col-12 col-md-6">
                                                                    <label class="form-label" for="contact">Phone
                                                                        Number</label>
                                                                    <input type="text" id="contact" name="contact"
                                                                        class="form-control phone-number-mask"
                                                                        placeholder="(0809) 357 0289"
                                                                        value="<%=profile.user?.phone%>" />
                                                                </div>



                                                                <div class="col-12 text-center mt-2 pt-50">
                                                                    <button type="button" id="edit-submit-btn"
                                                                        class="btn btn-success me-1"
                                                                        data-user-slug="TayeOluwafemiH865ldv4D31648997659">Submit</button>
                                                                    <button type="reset"
                                                                        class="btn btn-outline-secondary"
                                                                        data-bs-dismiss="modal" aria-label="Close">
                                                                        Discard
                                                                    </button>
                                                                </div>
                                                            </div>
                                                        </div>
                                                    </div>
                                                </div>

                                                <div class="main_content_iner ">
                                                    <div class="container-fluid">
                                                        <div class="row">
                                                            <div class="col-xl-4 col-lg-5 col-md-5">
                                                                <div class="card" style=" border-radius: 8px;">
                                                                    <div class="card-body">
                                                                        <div class="user-avatar-section">
                                                                            <div
                                                                                class="d-flex align-items-center flex-column">

                                                                                <% if(profile.photo_path){%>
                                                                                    <img src="/avatar/<%= profile.photo_path%>"
                                                                                        width="60px" alt="">
                                                                                    <%}else{%>
                                                                                        <img src="img/client_img.png"
                                                                                            width="60px" alt="">
                                                                                        <%}%>
                                                                                            <a href="#"
                                                                                                style="color: #038F3F;">Change
                                                                                                Picture</a>
                                                                                            <div class="text-center">
                                                                                                <h4>
                                                                                                    <%= profile?.lastname?.toUpperCase()
                                                                                                        %>, <%=
                                                                                                            profile?.firstname
                                                                                                            %>
                                                                                                            <%= profile?.middlename
                                                                                                                %>
                                                                                                </h4>
                                                                                            </div>
                                                                            </div>
                                                                        </div>
                                                                        <h4
                                                                            class="fw-bolder border-bottom pb-50 mb-1 mt-3">
                                                                            Details</h4>
                                                                        <div class="info-container">
                                                                            <ul class="list-unstyled">
                                                                                <li class="mt-2">
                                                                                    <span><b>Username:</b></span><br>
                                                                                    <span style="opacity: 0.5;">
                                                                                        <%= profile.user.username %>
                                                                                    </span>
                                                                                </li>
                                                                                <li class="mt-2">
                                                                                    <span><b>Email:</b></span><br>
                                                                                    <span style="opacity: 0.5;">
                                                                                        <%= profile.user.email %>
                                                                                    </span>
                                                                                </li>
                                                                                <li class="mt-2">
                                                                                    <span><b>Phone:</b></span><br>
                                                                                    <span style="opacity: 0.5;">
                                                                                        <%= profile.user.phone %>
                                                                                    </span>
                                                                                </li>
                                                                                <li class="mt-2">
                                                                                    <span><b>Department:</b></span><br>
                                                                                    <span style="opacity: 0.5;">
                                                                                        <%= profile.department.name %>
                                                                                    </span>
                                                                                </li>
                                                                                <li class="mt-2">
                                                                                    <span><b>Institute:</b></span><br>
                                                                                    <span style="opacity: 0.5;">
                                                                                        <%= profile.department.institute.name
                                                                                            %>
                                                                                    </span>
                                                                                </li>
                                                                            </ul>
                                                                            <div
                                                                                class="d-flex justify-content-center mt-3">
                                                                                <button href="javascript;"
                                                                                    class="btn btn-success me-1"
                                                                                    data-bs-target="#editUser"
                                                                                    data-bs-toggle="modal">
                                                                                    Edit
                                                                                </button>
                                                                            </div>
                                                                        </div>
                                                                    </div>
                                                                </div>
                                                            </div>

                                                            <div class="col-xl-8 col-lg-7 col-md-7"
                                                                style="border-radius: 8px;">

                                                                <ul class="nav nav-pills mb-2">
                                                                    <li class="nav-item">
                                                                        <%if(userType=="staff" ){%>
                                                                            <a class="nav-link active"
                                                                                style="background-color: #038F3F;"
                                                                                href="/student-account?user_id=<%=profile.user_id%>">
                                                                                <!-- <i data-feather="lock" class="font-medium-3 me-50"></i> -->
                                                                                <span class="fw-bold">Account</span>
                                                                            </a>
                                                                            <%}else{%>

                                                                                <a class="nav-link "
                                                                                    style="background-color: #038F3F;"
                                                                                    href="/student-account?user_id=<%=profile.user_id%>">
                                                                                    <!-- <i data-feather="lock" class="font-medium-3 me-50"></i> -->
                                                                                    <span class="fw-bold"
                                                                                        style="color: #ffff;">Account</span>
                                                                                </a>
                                                                                <%}%>
                                                                    </li>
                                                                    <li class="nav-item">
                                                                        <%if(userType=="staff" ){%>
                                                                            <a class="nav-link "
                                                                                href="/student-account-security?user_id=<%=profile.user_id%>">
                                                                                <!-- <i data-feather="lock" class="font-medium-3 me-50"></i> -->
                                                                                <span class="fw-bold"
                                                                                    style="color: #038F3F;">Security</span>
                                                                            </a>
                                                                            <%}else{%>

                                                                                <a class="nav-link "
                                                                                    href="/student-account-security?user_id=<%=profile.user_id%>">
                                                                                    <!-- <i data-feather="lock" class="font-medium-3 me-50"></i> -->
                                                                                    <span class="fw-bold"
                                                                                        style="color: #038F3F;">Security</span>
                                                                                </a>
                                                                                <%}%>
                                                                    </li>
                                                                    <!-- <li class="nav-item">
                          <a class="nav-link " 
                              href="/profile-payment">
                          <i data-feather="lock" class="font-medium-3 me-50"></i>
                          <span class="fw-bold">Payments</span>
                          </a>
                      </li> -->
                                                                </ul>

                                                                <div class="card">

                                                                    <div class="card-body">
                                                                        <h4 class="mt-2">Activity Timeline</h4>
                                                                        <ul class="timeline ms-50">
                                                                            <% for(activty of activityLog){%>
                                                                                <li class="timeline-item">
                                                                                    <div class="timeline-event">
                                                                                        <div
                                                                                            class="d-flex justify-content-between">
                                                                                            <h6>
                                                                                                <%= activty.description
                                                                                                    %>
                                                                                            </h6>
                                                                                            <span style="opacity: 0.5;">
                                                                                                <%= activty.createdAt %>
                                                                                            </span>
                                                                                        </div>
                                                                                        <p> Time
                                                                                        </p>
                                                                                    </div>
                                                                                </li>
                                                                                <%}%>
                                                                        </ul>
                                                                    </div>
                                                                </div>

                                                            </div>
                                                        </div>
                                                    </div>
                                                </div>
                                                </div>

                                                <div class="footer_part">
                                                    <div class="container-fluid">
                                                        <div class="row">
                                                            <div class="col-lg-12">
                                                                <footer class="footer footer-light  footer-static">
                                                                    <p class="clearfix mb-0">
                                                                        <span
                                                                            class="float-md-start d-block d-md-inline-block mt-25 text-center">COPYRIGHT
                                                                            &copy;
                                                                            <script>document.write(new Date().getFullYear())</script>
                                                                            <a class="ms-25" href="">CORASS</a>,
                                                                            <span class="d-inline-block">All rights
                                                                                Reserved</span>
                                                                        </span>
                                                                        <span
                                                                            class="float-md-end d-block text-center">Centralized
                                                                            Online Research Assessment and Submission
                                                                            System<i
                                                                                data-feather="file-text"></i></span>
                                                                    </p>
                                                                </footer>
                                                            </div>
                                                        </div>
                                                    </div>
                                                </div>
                        </section>


                        <div class="CHAT_MESSAGE_POPUPBOX">
                            <div class="CHAT_POPUP_HEADER">
                                <div class="MSEESAGE_CHATBOX_CLOSE">
                                    <svg width="12" height="12" viewBox="0 0 12 12" fill="none"
                                        xmlns="http://www.w3.org/2000/svg">
                                        <path
                                            d="M7.09939 5.98831L11.772 10.661C12.076 10.965 12.076 11.4564 11.772 11.7603C11.468 12.0643 10.9766 12.0643 10.6726 11.7603L5.99994 7.08762L1.32737 11.7603C1.02329 12.0643 0.532002 12.0643 0.228062 11.7603C-0.0760207 11.4564 -0.0760207 10.965 0.228062 10.661L4.90063 5.98831L0.228062 1.3156C-0.0760207 1.01166 -0.0760207 0.520226 0.228062 0.216286C0.379534 0.0646715 0.578697 -0.0114918 0.777717 -0.0114918C0.976738 -0.0114918 1.17576 0.0646715 1.32737 0.216286L5.99994 4.889L10.6726 0.216286C10.8243 0.0646715 11.0233 -0.0114918 11.2223 -0.0114918C11.4213 -0.0114918 11.6203 0.0646715 11.772 0.216286C12.076 0.520226 12.076 1.01166 11.772 1.3156L7.09939 5.98831Z"
                                            fill="white" />
                                    </svg>
                                </div>
                                <h3>Chat with us</h3>
                                <div class="Chat_Listed_member">
                                    <ul>
                                        <li>
                                            <a href="#">
                                                <div class="member_thumb">
                                                    <img src="img/staf/1.png" alt="">
                                                </div>
                                            </a>
                                        </li>
                                        <li>
                                            <a href="#">
                                                <div class="member_thumb">
                                                    <img src="img/staf/2.png" alt="">
                                                </div>
                                            </a>
                                        </li>
                                        <li>
                                            <a href="#">
                                                <div class="member_thumb">
                                                    <img src="img/staf/3.png" alt="">
                                                </div>
                                            </a>
                                        </li>
                                        <li>
                                            <a href="#">
                                                <div class="member_thumb">
                                                    <img src="img/staf/4.png" alt="">
                                                </div>
                                            </a>
                                        </li>
                                        <li>
                                            <a href="#">
                                                <div class="member_thumb">
                                                    <img src="img/staf/5.png" alt="">
                                                </div>
                                            </a>
                                        </li>
                                        <li>
                                            <a href="#">
                                                <div class="member_thumb">
                                                    <div class="more_member_count">
                                                        <span>90+</span>
                                                    </div>
                                                </div>
                                            </a>
                                        </li>
                                    </ul>
                                </div>
                            </div>
                            <div class="CHAT_POPUP_BODY">
                                <p class="mesaged_send_date">
                                    Sunday, 12 January
                                </p>
                                <div class="CHATING_SENDER">
                                    <div class="SMS_thumb">
                                        <img src="img/staf/1.png" alt="">
                                    </div>
                                    <div class="SEND_SMS_VIEW">
                                        <P>Hi! Welcome .
                                            How can I help you?</P>
                                    </div>
                                </div>
                                <div class="CHATING_SENDER CHATING_RECEIVEr">
                                    <div class="SEND_SMS_VIEW">
                                        <P>Hello</P>
                                    </div>
                                    <div class="SMS_thumb">
                                        <img src="img/staf/1.png" alt="">
                                    </div>
                                </div>
                            </div>
                            <div class="CHAT_POPUP_BOTTOM">
                                <div class="chat_input_box d-flex align-items-center">
                                    <div class="input-group">
                                        <input type="text" class="form-control" placeholder="Write your message"
                                            aria-label="Recipient's username" aria-describedby="basic-addon2">
                                        <div class="input-group-append">
                                            <button class="btn " type="button">

                                                <svg width="22" height="22" viewBox="0 0 22 22" fill="none"
                                                    xmlns="http://www.w3.org/2000/svg">
                                                    <path
                                                        d="M18.7821 3.21895C14.4908 -1.07281 7.50882 -1.07281 3.2183 3.21792C-1.07304 7.50864 -1.07263 14.4908 3.21872 18.7824C7.50882 23.0729 14.4908 23.0729 18.7817 18.7815C23.0726 14.4908 23.0724 7.50906 18.7821 3.21895ZM17.5813 17.5815C13.9525 21.2103 8.04773 21.2108 4.41871 17.5819C0.78907 13.9525 0.789485 8.04714 4.41871 4.41832C8.04752 0.789719 13.9521 0.789304 17.5817 4.41874C21.2105 8.04755 21.2101 13.9529 17.5813 17.5815ZM6.89503 8.02162C6.89503 7.31138 7.47107 6.73534 8.18131 6.73534C8.89135 6.73534 9.46739 7.31117 9.46739 8.02162C9.46739 8.73228 8.89135 9.30811 8.18131 9.30811C7.47107 9.30811 6.89503 8.73228 6.89503 8.02162ZM12.7274 8.02162C12.7274 7.31138 13.3038 6.73534 14.0141 6.73534C14.7241 6.73534 15.3002 7.31117 15.3002 8.02162C15.3002 8.73228 14.7243 9.30811 14.0141 9.30811C13.3038 9.30811 12.7274 8.73228 12.7274 8.02162ZM15.7683 13.2898C14.9712 15.1332 13.1043 16.3243 11.0126 16.3243C8.8758 16.3243 6.99792 15.1272 6.22834 13.2744C6.09642 12.9573 6.24681 12.593 6.56438 12.4611C6.64238 12.4289 6.72328 12.4136 6.80293 12.4136C7.04687 12.4136 7.27836 12.5577 7.37772 12.7973C7.95376 14.1842 9.38048 15.0799 11.0126 15.0799C12.6077 15.0799 14.0261 14.1836 14.626 12.7959C14.7625 12.4804 15.1288 12.335 15.4441 12.4717C15.7594 12.6084 15.9048 12.9745 15.7683 13.2898Z"
                                                        fill="#707DB7" />
                                                </svg>

                                            </button>
                                            <button class="btn" type="button">

                                                <svg width="22" height="22" viewBox="0 0 22 22" fill="none"
                                                    xmlns="http://www.w3.org/2000/svg">
                                                    <path
                                                        d="M11 0.289062C4.92455 0.289062 0 5.08402 0 10.9996C0 16.9152 4.92455 21.7101 11 21.7101C17.0755 21.7101 22 16.9145 22 10.9996C22 5.08472 17.0755 0.289062 11 0.289062ZM11 20.3713C5.68423 20.3713 1.375 16.1755 1.375 10.9996C1.375 5.82371 5.68423 1.62788 11 1.62788C16.3158 1.62788 20.625 5.82371 20.625 10.9996C20.625 16.1755 16.3158 20.3713 11 20.3713ZM15.125 10.3302H11.6875V6.98314C11.6875 6.61363 11.3795 6.31373 11 6.31373C10.6205 6.31373 10.3125 6.61363 10.3125 6.98314V10.3302H6.875C6.4955 10.3302 6.1875 10.6301 6.1875 10.9996C6.1875 11.3691 6.4955 11.669 6.875 11.669H10.3125V15.016C10.3125 15.3855 10.6205 15.6854 11 15.6854C11.3795 15.6854 11.6875 15.3855 11.6875 15.016V11.669H15.125C15.5045 11.669 15.8125 11.3691 15.8125 10.9996C15.8125 10.6301 15.5045 10.3302 15.125 10.3302Z"
                                                        fill="#707DB7" />
                                                </svg>

                                                <input type="file">
                                            </button>
                                        </div>
                                    </div>
                                </div>
                            </div>
                        </div>

                        <div id="back-top" style="display: none;">
                            <a title="Go to Top" href="#">
                                <i class="ti-angle-up"></i>
                            </a>
                        </div>

                        <script src="js/jquery1-3.4.1.min.js"></script>

                        <script src="js/popper1.min.js"></script>

                        <script src="../js/toastr.min.js"></script>
                        <script src="js/bootstrap1.min.js"></script>

                        <script src="js/metisMenu.js"></script>

                        <script src="vendors/count_up/jquery.waypoints.min.js"></script>

                        <script src="vendors/chartlist/Chart.min.js"></script>

                        <script src="vendors/count_up/jquery.counterup.min.js"></script>

                        <script src="vendors/niceselect/js/jquery.nice-select.min.js"></script>

                        <script src="vendors/owl_carousel/js/owl.carousel.min.js"></script>

                        <script src="vendors/datatable/js/jquery.dataTables.min.js"></script>
                        <script src="vendors/datatable/js/dataTables.responsive.min.js"></script>
                        <script src="vendors/datatable/js/dataTables.buttons.min.js"></script>
                        <script src="vendors/datatable/js/buttons.flash.min.js"></script>
                        <script src="vendors/datatable/js/jszip.min.js"></script>
                        <script src="vendors/datatable/js/pdfmake.min.js"></script>
                        <script src="vendors/datatable/js/vfs_fonts.js"></script>
                        <script src="vendors/datatable/js/buttons.html5.min.js"></script>
                        <script src="vendors/datatable/js/buttons.print.min.js"></script>
                        <script src="js/chart.min.js"></script>

                        <script src="vendors/progressbar/jquery.barfiller.js"></script>

                        <script src="vendors/tagsinput/tagsinput.js"></script>

                        <script src="vendors/text_editor/summernote-bs4.js"></script>
                        <script src="vendors/am_chart/amcharts.js"></script>

                        <script src="vendors/scroll/perfect-scrollbar.min.js"></script>
                        <script src="vendors/scroll/scrollable-custom.js"></script>
                        <script src="vendors/chart_am/core.js"></script>
                        <script src="vendors/chart_am/charts.js"></script>
                        <script src="vendors/chart_am/animated.js"></script>
                        <script src="vendors/chart_am/kelly.js"></script>
                        <script src="vendors/chart_am/chart-custom.js"></script>

                        <script src="//cdn.jsdelivr.net/npm/sweetalert2@11"></script>
                        <script src="js/corass.js"></script>
                        <script src="js/custom.js"></script>
</body>

</html>