I have number of models say : A1, A2 A3 & A4.
There will be views for each of these models (like List or Create , Edit etc.,.)
However my views should not have any static html in it, I have to render the html by using some Html Helper methods.
Probably I should write a method in RenderHelper.cs like below
public static MvcHtmlString RenderContent(this HtmlHelper helper, IEnumerable<FatRoute> model)
{
}
also, I have to check the type of column in the model to render textbox or dropdown or datetime according to its type.
The problem here is, the columns are diff foreach model (obviously) and I cannot have diff blocks of code to check the column types for each model. If I say item. (here I get the columns in the item) in foreach bolck, I get only the columns of the passed model. But it should be some generic way to handle all models.
can somebody advise how to achiev this?