widget.profile.php 1.2 KB

123456789101112131415161718192021222324
  1. <?php
  2. global $myUser;
  3. $function = !empty($myUser->function) ? $myUser->function : 'Employé';
  4. $phone = !empty($myUser->phone) ? $myUser->phone : '';
  5. $mail = !empty($myUser->mail) ? $myUser->mail : '';
  6. ?>
  7. <div class="profileContainer">
  8. <div class="profileHeader" style="<?php echo 'background-color:'.$widget->data('background-color'); ?>"></div>
  9. <div class="profileImage">
  10. <a href="account.php"><img class="avatar-mini" src="<?php echo $myUser->getAvatar(); ?>"><div title="Éditer mon profil" class="edit-overlay"></div></a>
  11. </div>
  12. <div class="profile-content">
  13. <h3 class="w-100"><?php echo $myUser->fullname(); ?></h3>
  14. <small><?php echo $function; ?></small><br>
  15. <small><?php echo $phone; ?> <a href="mailto:'.$mail.'"><?php echo $mail; ?></a></small>
  16. </div>
  17. <div class="profile-buttons">
  18. <a href="account.php" class="btn text-uppercase"><i class="far fa-meh-blank"></i> Profil</a>
  19. <a href="account.php?section=notification" class="btn text-uppercase"><i class="fas fa-bell"></i> Notifications</a>
  20. <a onclick="core_logout();" class="btn text-danger text-uppercase"><i class="fas fa-sign-out-alt"></i> Déconnexion</a>
  21. <div class="clear"></div>
  22. </div>
  23. </div>