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

C# Creating Razor templates For this assignment we are going to practice creating Razor templates, but the first thing we are going to do is

C#

Creating Razor templates

For this assignment we are going to practice creating Razor templates, but the first thing we are going to do is set up our web application to be ready for all the assignments we will do throughout the class. For this we will be adding to the menu and putting a drop down menu item all the way to the right named "Assignments". In here you will put all your assignments and these menu items will point to the new code developed to meet the requirements of the assignment. I will only look at the code in this spot when grading your assignment.

Acceptance criteria:

  • Create a new drop down menu item under the Assignments drop down called "Assignment 6.1"
  • Create a new controller for this assignment
  • This new page must accept a route parameter that is an integer between 1 and 10 for access level
  • Create a Student model class with the following properties (FirstName, LastName, Grade)
  • Create view model which contains a list of Student objects and the access level from the route parameter
  • Using Razor loops, conditionals, and partial views create a view.
    • If the access level is less than 2 show only "You do not have a sufficient access level to view this data."
    • If the access level is greater than 2 but less than 8 show a line for each student, but only display FirstName and LastName NOT Grade.
    • If the access level is greater than or equal to 8 show a line for each student with FirstName, LastName, and Grade. Also display "Hello Admin" above the list of students.
  • You may put any appropriate names and valid grades you wish and your list must contain between 3 and 5 students.

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

Database Machine Performance Modeling Methodologies And Evaluation Strategies Lncs 257

Authors: Francesca Cesarini ,Silvio Salza

1st Edition

3540179429, 978-3540179429

More Books

Students explore these related Databases questions