From 1254b0a81f8d4b2ca0ed0846369ec72a2e90f86b Mon Sep 17 00:00:00 2001 From: "lucie.goigoux2" Date: Tue, 21 Nov 2023 11:49:12 +0100 Subject: [PATCH 1/3] =?UTF-8?q?Cr=C3=A9ation=20vue=20vocabList?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Project/php/controller/StudentController.php | 8 ++++++++ Project/php/css/memory.css | 6 +++--- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/Project/php/controller/StudentController.php b/Project/php/controller/StudentController.php index 1e716d7..aef6772 100755 --- a/Project/php/controller/StudentController.php +++ b/Project/php/controller/StudentController.php @@ -35,4 +35,12 @@ class StudentController extends UserController $vocab = $mdl->getVocabByName($name); echo $twig->render('manageVocabView.html', ['vocabularies' => $vocab]); } + + public function memoryChoice(): void { + global $twig; + global $user; + $model = new MdlStudent(); + $voc = $model->getAll(); + echo $twig->render('vocabList.html', ['vocabularies' => $voc, 'userID' => $user->getId(), 'userRole' => $user->getRoles()]); + } } \ No newline at end of file diff --git a/Project/php/css/memory.css b/Project/php/css/memory.css index 3a2ce94..2fbef9a 100755 --- a/Project/php/css/memory.css +++ b/Project/php/css/memory.css @@ -2,9 +2,9 @@ body { display: flex; justify-content: center; align-items: center; - height: 90vh; + height: 90%; background-color: #acc2c2; - margin: 2vh 15vh; + margin: 2% 15%; overflow: hidden; } @@ -36,7 +36,7 @@ h1{ cursor: pointer; transition: transform 0.6s ease; transform-style: preserve-3d; - min-height: 5vh; + min-height: 5%; max-width: 100%; aspect-ratio: 1/1; } From fbfbb27474df600989de1f03254e0f716ad399fb Mon Sep 17 00:00:00 2001 From: "lucie.goigoux2" Date: Tue, 21 Nov 2023 11:49:32 +0100 Subject: [PATCH 2/3] =?UTF-8?q?Cr=C3=A9ation=20vue=20vocabList?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Project/php/templates/navBar.twig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Project/php/templates/navBar.twig b/Project/php/templates/navBar.twig index 12b403f..71aec62 100755 --- a/Project/php/templates/navBar.twig +++ b/Project/php/templates/navBar.twig @@ -16,7 +16,7 @@ {% endif %} {% if 'student' in userRole%} - + {% endif %} From cb85102b3d04dbc654aee0f33e3381687b41e17a Mon Sep 17 00:00:00 2001 From: "lucie.goigoux2" Date: Tue, 21 Nov 2023 11:50:30 +0100 Subject: [PATCH 3/3] Ajout vocablist --- Project/php/templates/vocabList.html | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100755 Project/php/templates/vocabList.html diff --git a/Project/php/templates/vocabList.html b/Project/php/templates/vocabList.html new file mode 100755 index 0000000..1aeea61 --- /dev/null +++ b/Project/php/templates/vocabList.html @@ -0,0 +1,28 @@ + + + + + Users + + + + + +{% include 'navBar.twig' %} +{% if vocabulary is defined %} +
+
+ + + {% for row in vocabularies %} + + {% endfor %} + +
+ +
+
+
+{% endif %} + + \ No newline at end of file