Giter VIP home page Giter VIP logo

university-project---study-plan's Introduction

Exam #1: "StudyPlan"

React Client Application Routes

  • Route /: The main page of the website which shows the list of all the courses and their information like course name and its code
  • Route /login: The login form is shown here and the user can login to they user-panel through this page by entering their username and password
  • Route /user-panel: User will be able to create their study plan and drag and drop their desired courses into the created study plan

API Server

  • POST /api/login

  • POST /api/register

    • request body: {"email":"[email protected]","password":"****","name":"John","surname":"Snow"}
    • response body content: {"result":true}
  • POST /api/logout

    • No request body or response body
  • POST /api/studyplan

    • request body: {"type":"partTime"}
    • response body: {"type":"Part time","maxCredits":40,"minCredits":20,"id":6}
  • GET /api/studyplan

    • response body:
      {
          "id": 8,
          "minCredits": 20,
          "maxCredits": 40,
          "type": "Part time",
          "userId": 1,
          "courses": [
              {
              "id": 1,
              "code": "02GOLOV",
              "name": "Architetture dei sistemi di elaborazione",
              "credit": 12,
              "incompatibleCoursesId": [
                  "02LSEOV"
              ],
              "preparatoryCoursesId": [],
              "maxStudents": -1,
              "incompatibleCourses": [
                  {
                  "id": 2,
                  "code": "02LSEOV",
                  "name": "Computer architectures",
                  "credit": 12,
                  "incompatibleCoursesId": "02GOLOV",
                  "preparatoryCoursesId": null,
                  "maxStudents": -1
                  }
              ],
              "preparatoryCourses": [],
              "enrolled": 1
              },
              {
              "id": 9,
              "code": "01UDUOV",
              "name": "Sicurezza dei sistemi informativi ",
              "credit": 12,
              "incompatibleCoursesId": [
                  "01TYMOV"
              ],
              "preparatoryCoursesId": [],
              "maxStudents": -1,
              "incompatibleCourses": [
                  {
                  "id": 8,
                  "code": "01TYMOV",
                  "name": "Information systems security services",
                  "credit": 12,
                  "incompatibleCoursesId": "01UDUOV",
                  "preparatoryCoursesId": null,
                  "maxStudents": -1
                  }
              ],
              "preparatoryCourses": [],
              "enrolled": 1
              }
          ]
      }
      
  • DELETE /api/studyplan

    • response body: {"lastID":34,"changes":1}
  • PUT /api/studyplan/:planId/courses

    • request parameter: 9
    • request body: [12,1,19,20]
  • GET /api/courses

    • response body:
    [
      {
          "id": 1,
          "code": "02GOLOV",
          "name": "Architetture dei sistemi di elaborazione",
          "credit": 12,
          "incompatibleCoursesId": [
          "02LSEOV"
          ],
          "preparatoryCoursesId": [],
          "maxStudents": -1,
          "incompatibleCourses": [
          {
              "id": 2,
              "code": "02LSEOV",
              "name": "Computer architectures",
              "credit": 12,
              "incompatibleCoursesId": "02GOLOV",
              "preparatoryCoursesId": null,
              "maxStudents": -1
          }
          ],
          "preparatoryCourses": [],
          "enrolled": 1
      },
      {
          "id": 2,
          "code": "02LSEOV",
          "name": "Computer architectures",
          "credit": 12,
          "incompatibleCoursesId": [
          "02GOLOV"
          ],
          "preparatoryCoursesId": [],
          "maxStudents": -1,
          "incompatibleCourses": [
          {
              "id": 1,
              "code": "02GOLOV",
              "name": "Architetture dei sistemi di elaborazione",
              "credit": 12,
              "incompatibleCoursesId": "02LSEOV",
              "preparatoryCoursesId": null,
              "maxStudents": -1
          }
          ],
          "preparatoryCourses": [],
          "enrolled": 4
      }
      ...
    ]
    

Database Tables

  • Table user - contains: id, name, surname, email, password, salt
  • Table studyplan - contains: id, minCredit, maxCredit, type, userId
  • Table course - contains: id, code, name, credit, incompatibleCoursesId, preparatoryCoursesId, maxStudents
  • Table scr - contains: id, cId, spId
  • ...

Main React Components

  • Accordion (in /components/accordion/accordion.component.js): It shows the course info like a foldable accordion
  • AccordionList (in /components/accordionList/accordion.component.js): Contains the list of accordions
  • BlankStudyPlan (in /components/blankStudyPlan/blankStudyPlan.component.js): It is shown when the studyplan is not created yet, it contains two buttons for creating 'full-time' or 'part-time' studyplans
  • CourseDetails (in /components/corseDetails/corseDetails.component.js): On the main page when the users are not logged in this component is shown which presents the information about the courses when they are selected
  • Loading (in /components/loading/loading.component.js): This component is shown instead of the main components when the data isn't gotten from the server and they are not ready yet
  • Navbar (in /components/navbar/navbar.component.js): This is the navbar of the site
  • StudyPlan (in /components/studyPlan/studyPlan.component.js): When a user creates a studyplan these components is shown and the user can do actions like add, remove, modify ... through the interaction with this one, this component is consist of these other components: StudyPlanHeader, StudyPlanTable, StudyPlanTableElement

Paged

    • LoginPage (in /pages/login/login.page.js): The login page
    • MainPage (in /pages/mainPage/main.page.js): The main page, it is shown when user isn't logged in yet
    • UserPanelPage (in /pages/userPanel/userPanel.page.js): The user panel page

Screenshots

Main page

Screenshot

Login / Register page

Screenshot

Login / Register page

Screenshot

User-panel: When study plan isn't created

Screenshot

User-panel: choose studyplan type

Screenshot

User-panel: Fresh studyplan

Screenshot

User-panel: With studyplan and courses

Screenshot

Users Credentials

Username Password
[email protected] testpassword
[email protected] testpassword
[email protected] testpassword
[email protected] testpassword
[email protected] testpassword

university-project---study-plan's People

Contributors

ssz360 avatar github-classroom[bot] avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.