From 7e19eb7a76c903b6c6106c9a5f05bad73542297c Mon Sep 17 00:00:00 2001 From: = Date: Wed, 20 Jan 2021 20:18:16 +0200 Subject: [PATCH 1/3] Project struncture --- README.md | 89 +++++++++++++++++++++++++++++++++++++++++++++++++++---- app.json | 3 +- 2 files changed, 86 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index c52c360..ead9198 100644 --- a/README.md +++ b/README.md @@ -1,10 +1,89 @@ # LMS MobileApp using React-Native framework -### Setup the project: -- Fork -- git clone {project URL} +## Project structure: +. +├── App.js +├── README.md +├── package.json +└── shared +│ └── index.js +├── navigation +│ ├── BottomNavigation.js +│ └── Header.js +├── icons +├── assets +└── screens + ├── Admin + │ ├── Admin.js + │ └── screens + │ ├── Main + │ │ └── Main.js + │ ├── AcceptUser + │ │ ├── AcceptUser.js + │ │ └── components + │ │ ├── StudentList.js + │ │ └── TeacherLIst.js + │ ├── CreateCourse + │ │ └── CreateCourse.js + │ └── CreateUser + │ └── CreateUser.js + ├── StudentDash + │ ├── StudentDashboard.js + │ └── screens + │ ├── Main + │ │ ├── Main.js + │ │ └── components + │ │ ├── Modal.js + │ │ └── SubjectCard.js + │ ├── Assignments + │ │ ├── Assignments.js + │ │ └── components + │ │ └── AssCard.js + │ ├── AssScreen + │ │ ├── AssScreen.js + │ ├── CourseMaterial + │ │ ├── CourseMaterial.js + │ │ └── components + │ │ └── ContentList.js + │ ├── Discussion + │ │ ├── Discussion.js + │ ├── OpenMaterial + │ │ ├── OpenMaterial.js + │ ├── Quizes + │ │ ├── Quizes.js + │ │ └── components + │ │ └── QuizzCard.js + │ ├── QuizzScreen + │ ├── QuizzScreen.js + └── TeacherDash + │ ├── TeacherDashboard.js + │ └── screens + │ ├── Main + │ │ └── Main.js + │ ├── Announce + │ │ └── Announce.js + │ ├── Assignments + │ │ └── Assignments.js + │ ├── CourseSpecification + │ │ └── CourseSpecification.js + │ ├── CreateQuiz + │ │ └── CreateQuiz.js + │ ├── DIsplayAsses + │ │ └── DIsplayAsses.js + │ ├── GradeAss + │ │ └── GradeAss.js + │ ├── PostLearningMaterials + │ │ └── PostLearningMaterials.js + │ └── TeacherDiscussion + │ └── TeacherDiscussion.js + └── Login + └── Login.js + +### Setup the project: +- ** You should have node.js & expo-cli installed ** if not run npm install expo-cli +- run git clone {project URL} - cd MobileApp - npm install - expo start -- check trick -#### We will use nativebase for UI components: https://docs.nativebase.io/Components.html#Components + +#### We will use react-native-paper for UI components: https://docs.nativebase.io/Components.html#Components diff --git a/app.json b/app.json index daff8ad..78a4c5b 100644 --- a/app.json +++ b/app.json @@ -17,7 +17,8 @@ "**/*" ], "ios": { - "supportsTablet": true + "supportsTablet": true, + "bundleIdentifier": "LMS" }, "android": { "adaptiveIcon": { From 8d89d44c62682d66c8e920d49ff439bff393d8df Mon Sep 17 00:00:00 2001 From: = Date: Sun, 24 Jan 2021 23:57:46 +0200 Subject: [PATCH 2/3] fix accept user displayed names --- App.js | 4 ++-- screens/Admin/screens/AcceptUser/AcceptUser.js | 2 +- screens/Admin/screens/AcceptUser/components/StudentsList.js | 3 ++- screens/Admin/screens/AcceptUser/components/TeacherList.js | 3 ++- screens/StudentDash/screens/Main/Main.js | 6 +++++- 5 files changed, 12 insertions(+), 6 deletions(-) diff --git a/App.js b/App.js index a4d071c..6b672c3 100644 --- a/App.js +++ b/App.js @@ -48,9 +48,9 @@ export default function App() { - + {/* */} {/* */} - {/* */} + {/* { extraData={items} renderItem={(student) => ( - {student.item.username} + {student.item.name} { console.log("student'", items, student.item.selected); diff --git a/screens/Admin/screens/AcceptUser/components/TeacherList.js b/screens/Admin/screens/AcceptUser/components/TeacherList.js index a285791..84b0cfa 100644 --- a/screens/Admin/screens/AcceptUser/components/TeacherList.js +++ b/screens/Admin/screens/AcceptUser/components/TeacherList.js @@ -19,7 +19,8 @@ const Header = ({ items, handleCheck, title, index }) => { extraData={items} renderItem={(student) => ( - {student.item.username} + {student.item.name} + {console.log("student",student)} { diff --git a/screens/StudentDash/screens/Main/Main.js b/screens/StudentDash/screens/Main/Main.js index 5c277dc..f52615e 100644 --- a/screens/StudentDash/screens/Main/Main.js +++ b/screens/StudentDash/screens/Main/Main.js @@ -1,5 +1,6 @@ import React, { useState, useEffect } from "react"; -import { View, StyleSheet, ScrollView } from "react-native"; +import { View, StyleSheet, ScrollView ,Text} from "react-native"; + import Submit from "../../../../shared/Submit"; import Input from "../../../../shared/Input"; import axios from "axios"; @@ -50,6 +51,9 @@ export default ({ navigation }) => { return ( + + HELLO WORLD + Date: Mon, 25 Jan 2021 00:48:02 +0200 Subject: [PATCH 3/3] click on box to toggle --- .../AcceptUser/components/StudentsList.js | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) diff --git a/screens/Admin/screens/AcceptUser/components/StudentsList.js b/screens/Admin/screens/AcceptUser/components/StudentsList.js index 0461abb..d79f28b 100644 --- a/screens/Admin/screens/AcceptUser/components/StudentsList.js +++ b/screens/Admin/screens/AcceptUser/components/StudentsList.js @@ -13,25 +13,31 @@ import { FlatList } from "react-native"; const Header = ({ items, handleCheck, title, index }) => { return ( + + ( + renderItem={(student) => ( handleCheck(student.index, student.item.selected)} + > - {student.item.name} + {student.item.name} { - console.log("student'", items, student.item.selected); - handleCheck(student.index, student.item.selected); + handleCheck(student.index, student.item.selected); }} /> + )} /> + + ); }; export default Header;