3
How do I render 2 view typed of controllers different?
Controller:
public ActionResult Index()
{
Cliente cli = new Cliente();
cli.Nome = "Al Unser";
return View(cli);
}
Index:
@model MvcRazor.Entidades.Cliente
@{
ViewBag.Title = @Model.Nome;
}
<h2 id="teste">@Model.Nome</h2>
@Html.Partial("~/Views/Shared/_Pedidos.cshtml")
<script src="~/Scripts/Home.js"></script>
Partial View:
@model MvcRazor.Entidades.Pedido
<h1>@Model</h1>