From the course: Building Angular and ASP.NET Web API Apps
Unlock the full course today
Join today to access over 22,600 courses taught by industry experts or purchase this course individually.
Showing data to the users
From the course: Building Angular and ASP.NET Web API Apps
Showing data to the users
- [Instructor] So, on the last part we designed our table using the material design, but still we don't see any data in our application. On this part, we are going to see how we can get the data from the database and show them in our table. So let us go to our project. In the entries.component.html file, we have defined that the dataSource is going to be named dataSource, which means that we should have a variable, which is going to hold all the data coming from the database, and then this table will use that source to display all the data. Since we are here, let us remove the button that we created on the previous part, because we don't need that anymore, and then go back to the entries.component.ts. In here, let us define the dataSource. Now, to fill in this dataSource with data, we are going to write some code inside the subscribe method, because inside this method, we get the data or the response from our web api endpoint. For that, let us write here this.dataSource, is equal to…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.
Contents
-
-
-
-
-
(Locked)
Adding a component3m 8s
-
(Locked)
Adding a service2m 55s
-
(Locked)
Configuring routing in Angular6m 51s
-
(Locked)
Requesting data from Web API7m 29s
-
(Locked)
Designing a view with Material Design5m 26s
-
(Locked)
Creating a Material Design table5m 30s
-
(Locked)
Showing data to the users4m 8s
-
(Locked)
-
-
-
-
-
-