Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

This question consists of two parts. The first part will consist of creating a Web API that will do CRUD (create, read, update, and delete)

This question consists of two parts. The first part will consist of creating a Web API that will do CRUD (create, read, update, and delete) operations on courses. The second part will consist of an Angular application that will interact with the API and call the different methods in the web API.


Web API

Create a web project called coursesAPI.
Add a class called Instructor containing the variables firstname and lastname.

Create another class called Course containing three variables ID, title, crn, and another variable of type Instructor called instructor.


Create a class called CourseInitializer that creates a list of 3 courses and puts that in the cache.

Create the folder: Controller and in it create a controller called CourseController.

Create the CRUD operations (create, read, update, and delete) using proper HTTP verbs

  • -GetCourses: gets all courses
  • -GetCourse: gets a course by ID
  • -CreateCourse: creates a course
  • -UpdateCourse: updates the course’s title
  • -DeleteCourse: deletes a course by ID

Make sure you use the proper HTTP verb for these methods.



Step by Step Solution

3.47 Rating (163 Votes )

There are 3 Steps involved in it

Step: 1

To create the Web API you can follow these steps 1 Create a new ASPNET Web Application project in Visual Studio Choose the Web API template 2 Create the Instructor and Course classes in the Models fol... 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

Auditing and Assurance Services A Systematic Approach

Authors: William Messier, Steven Glover, Douglas Prawitt

9th edition

1308361491, 77862333, 978-1259248290, 9780077862336, 1259162346, 978-1259162343

More Books

Students also viewed these Databases questions

Question

mple 10. Determine d dx S 0 t dt.

Answered: 1 week ago