diff --git a/backend/assets/img/logo/logo-ffessm.png b/backend/assets/img/logo/logo-ffessm.png new file mode 100644 index 0000000..c163335 Binary files /dev/null and b/backend/assets/img/logo/logo-ffessm.png differ diff --git a/backend/assets/img/site/compte/troll-qr-code.jpg b/backend/assets/img/site/compte/troll-qr-code.jpg new file mode 100644 index 0000000..b3a9767 Binary files /dev/null and b/backend/assets/img/site/compte/troll-qr-code.jpg differ diff --git a/backend/src/DataFixtures/AppFixtures.php b/backend/src/DataFixtures/AppFixtures.php index 83b84e0..be84122 100644 --- a/backend/src/DataFixtures/AppFixtures.php +++ b/backend/src/DataFixtures/AppFixtures.php @@ -51,7 +51,7 @@ public function load(ObjectManager $manager): void // Ajouter une licence à l'admin $licence = new Licence(); $licence - ->setNumber(number: '123456') + ->setNumber(number: 'A-17-776251') ->setUserLicence(user_licence: $admin); $manager->persist($licence); diff --git a/backend/src/Entity/User.php b/backend/src/Entity/User.php index 4581596..c4e6136 100644 --- a/backend/src/Entity/User.php +++ b/backend/src/Entity/User.php @@ -122,6 +122,9 @@ class User implements UserInterface, PasswordAuthenticatedUserInterface #[ORM\Column(nullable: true)] private ?\DateTimeImmutable $account_deletion_request = null; + /** + * @throws \Exception + */ public function __construct() { $this->createdAt = new \DateTimeImmutable(timezone: new \DateTimeZone(timezone: self::TIMEZONE)); @@ -132,6 +135,15 @@ public function __construct() } } + public function getFullname(): string + { + // Capitalize the first letter of the firstname and the lastname + $firstname = ucfirst(strtolower($this->firstname)); + $lastname = ucfirst(strtolower($this->lastname)); + + return $firstname.' '.$lastname; + } + public function getId(): ?int { return $this->id; diff --git a/backend/templates/pages/account/account-overview.html.twig b/backend/templates/pages/account/account-overview.html.twig index 9a91345..e5ffc55 100644 --- a/backend/templates/pages/account/account-overview.html.twig +++ b/backend/templates/pages/account/account-overview.html.twig @@ -76,16 +76,52 @@ + {# --------------------------Composant Licence FFESSM------------------------ #} +
-
- Entrainement piscine icône -

Entrainement

-

Mardi à 19h00

-

Jeudi à 20h00

+
+
+ Logo FFESSM +

IMMERSION & EMOTION

+
+
+
licence
+ troll qr-code +

{{ app.user.fullname }}

+ {% if app.user.divingLevel is null %} +
+ + Plongeur débutant +
+ {% else %} +
+ {% if app.user.divingLevel == 1 %} + + {% elseif app.user.divingLevel == 2 %} + + + {% elseif app.user.divingLevel == 3 %} + + + + {% endif %} +
+ {% endif %} +

{{ app.user.licence }}

+
+
+
+