Java Persistence API (JPA) Design

Objective

Create a ThymeLeaf JPA program that allows the user to input employees and display the requested employee data per a console menu.

Skills Required

  • Spring Boot
  • Object Oriented Programming
  • MVC Design Pattern
  • Collections
  • Abstraction
  • Polymorphism
  • Encapsulation

Iterations

Build the application in the following small iterations. It should function at completion of each iteration! Must include for each model a minimum of 10 data items. Please see #6 for an idea on what type of data to include.

  1. Write a model called Employee and it contains the following:

    • Encapsulated data:

      • Identification
      • Employee name as:

        • First
        • Middle
        • Last
        • Suffix
      • Make model a one to one relationship to Address
      • Make model a many to many relationship to Project
  2. Write a controller for Employee

  3. Write a repository for Employee

  4. Write a model called Address and it contains the following:

    • Encapsulated data:

      • Identification
      • Address as:

        • Address Line 1
        • Address Line 2
        • Apartment Number
        • City
        • State
        • Zip
        • Zip + Four
        • County
        • Country
    • Make model a one to many relationship to Employee
  5. Write a controller for Address

  6. Write a repository for Address

  7. Write a model called Project and it contains the following:

    • Encapsulated data:

      • Identification
      • Project Name
    • Make model a many to many relationship to Employee
  8. Write a controller for Project

  9. Write a repository for Project

  10. Write a ThymeLeaf template(s) to allow the user to search for the following information:

    • All employees
    • All addresses
    • All Employees with last name of Holland
    • All Addresses of employees with last name of Bell
    • Employee with ID of 7L
    • All Addresses with Hamilton as its county
    • All Addresses with Hamilton as its county and TN as its state
    • All Employees with first name of Henry
  11. Use CSS Grid or Flexbox to style the templates to have an consistent look and feel.