MVC Dynamic View Data and Dynamic Views

前端 未结 2 704
故里飘歌
故里飘歌 2021-02-03 16:30

Traditionally, I have built MVC applications using view models with Data Annotations attributes, and I dynamically render the views using editor templates. Everything works gre

2条回答
  •  别跟我提以往
    2021-02-03 16:58

    You can use The ViewData Property in your ViewModel, View and Controller, it is dynamic, so it can be resolved at runtime.

提交回复
热议问题