When I debug the application, I get the following error:
'StoreIndexData' does not contain a definition for 'DepartmentName' and no extension method 'DepartmentName' accepting a first argument of type 'StoreIndexData' could be found (are you missing a using directive or an assembly reference?)
#pragma warning restore 1998
'StoreIndexData' does not contain a definition for 'DepartmentID' and no extension method 'DepartmentID' accepting a first argument of type 'StoreIndexData' could be found (are you missing a using directive or an assembly reference?)
#pragma warning restore 1998
So, which would be the correct way to use the tag helpers in this case?
I tried to debug the application deleting the asp-for tag helper and it runs as expected, but I don't believe this is the right thing to do. Any explanation on why is it important to use this tag helper?
Thanks!
_EDIT:
Ok, so first, since I'm using a ViewModel, I would need to access the model that contains this property, which is Department, like this:
Manikandan MurugesanPosted Jun 23, 2017, 8:34 PM