0
I’m placing a table inside the Edit view.
View de Edit (Contract)
@if (Model.ContratoParcela.Any())
{
<table class="table parcela-lista">
@foreach (var parcela in Model.ContratoParcela)
{
<tr>
<th>
<a href="#" data-contratoid="@parcela.id_Contrato" data-toggle="modal" data-target="#ModalParcelaEdit">@parcela.valor</a>
</th>
</tr>
}
</table>
}
But @if is in red, underlined.
I want to take the information from the Contratoparcela table and display in the Edit view that comes from the Contract table.
I make that mistake:
Unexpected "if" keyword after "@" Character. Once Inside code, you do not need to prefix constructs like "if" with "@".
Take @ out of the front of the if.
– Jéf Bueno
Was that right? Just take the @, Marcos?
– Jéf Bueno