Answered step by step
Verified Expert Solution
Link Copied!
Question
1 Approved Answer

Create a WPF app that will read, insert, update and delete for each item of data and uses LINQ to select your data. Your app

  • Create a WPF app that will read, insert, update and delete for each item of data and uses LINQ to select your data. Your app should come preloaded with 5 pieces of data for each collection.
  • Start with a WPF with a login screen (1st window) where you hardcode the login data into a collection and compare the users login entry with your collection.
  • Upon successful login, load a window (2nd window) with multiple buttons (View Customers, View Flights, View Airlines, View Passengers) where by clicking on each button a new window for that particular category appears.
  • Each category window with its own ListBox to display each collections data. Allow for textboxes to insert/update/delete data for that particular collection.
  • Show a message box with an error message for incorrect login.
  • MealAvailable and Airplane will be a hardcoded Radiobuttons
  • Anything considered a foreign key should be a listbox displaying 1 item from that corresponding Collection.
  • Have a context menu (right click menu) with insert update and delete.

Instructions continued

  • Have a menu bar (top menu, or file menu) on each window (except login window) with:
  • File (New, Save, Quit quit will be the only working button to actually quit the application)
  • Edit (Insert, Update, Delete all will work to do that operation on the tab that is opened on the item selected in the listbox)
  • Show a message box with an error message if nothing is selected or there are empty text boxes
  • Show a message box if the foreign key does not exist (see foreign key comment in the Object Collection slides)
  • Help (launches new Window that serves as an about page)
  • Homepage only - View Customers, View Flights, View Airlines, View Passengers
  • Note: all windows should have a different color than the default grey.
  • Note: should have a message box asking the user to confirm quitting the application.
  • Note: You should have a message box asking the user to confirm if they wish to delete or update the data for all collections.
  • Note: See visual diagram for screen layouts (grid vs stackview)

Object Collection 1

  • Create a C# class called Customer containing
  • ID (int)
  • Name (string)
  • Address (string)
  • Email (string)
  • Phone (string)
  • Create a List to store a collection of these objects.

Object Collection 2

  • Create a C# class called Flights containing
  • ID (int)
  • airlineID (int should be id of an airline from object collection 3, ie. Think of it like a foreign key in databases)
  • DepartureCity (string)
  • DestinationCity (string)
  • DepartureDate (string)
  • FlightTime (double) (number of hours)
  • Create a List to store a collection of these objects.

Object Collection 3

  • Create a C# class called Airlines containing
  • ID (int)
  • Name (string)
  • Airplane (string) (ex. Boeing 777, Airbus 320, etc)
  • SeatsAvailable (int)
  • MealAvailable (string) (ex. Chicken, Sushi, Salad, etc)
  • Create a List to store a collection of these objects.

Object Collection 4

  • Create a C# class called Passenger containing
  • ID (int)
  • customerID (int should be id of customer from object collection 1, ie. Think of it like a foreign key in databases)
  • flightID (int should be id of flight from object collection 2, ie. Think of it like a foreign key in databases)
  • Create a List to store a collection of these objects.

Object Collection 0 Login Details

  • Create a table called Logins containing
  • ID (int)
  • Username (string)
  • Password (string)
  • SuperUser (int) // 1 for super user, 0 for regular user
  • Create a Dictionary to store a collection of these objects.
  • The key will be the Username.
  • Have the SuperUser field dictate whether or not a logged in user can add/update/delete (give a message box error message if the user is attempting to perform these operations and SuperUser=0)
  • Also create a window that is launched from the File menu that allows for insert, update, delete of users but only if SuperUser=1
  • Note: there will be no insert/update/delete/view operations for Login, just hardcode with 5 predefined users into Dictionary.

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image
Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Advances In Databases And Information Systems 22nd European Conference Adbis 2018 Budapest Hungary September 2 5 2018 Proceedings Lncs 11019

Authors: Andras Benczur ,Bernhard Thalheim ,Tomas Horvath

1st Edition

3319983970, 978-3319983974

More Books

Students explore these related Databases questions