Skip to content

Instantly share code, notes, and snippets.

@icebeam7
Last active January 9, 2021 15:14
Show Gist options
  • Save icebeam7/0af0d9c669ef03d076da2da23015b7fe to your computer and use it in GitHub Desktop.
Save icebeam7/0af0d9c669ef03d076da2da23015b7fe to your computer and use it in GitHub Desktop.
Views/Estudiante/Create.cshtml
@model UniversidadWebsite.Models.Estudiante
@{
ViewData["Title"] = "Create";
}
<h1>Create</h1>
<h4>Estudiante</h4>
<hr />
<div class="row">
<div class="col-md-4">
<form asp-action="Create" enctype="multipart/form-data">
<div asp-validation-summary="ModelOnly" class="text-danger"></div>
<div class="form-group">
<label asp-for="Cedula" class="control-label"></label>
<input asp-for="Cedula" class="form-control" />
<span asp-validation-for="Cedula" class="text-danger"></span>
</div>
<div class="form-group">
<label asp-for="Nombre" class="control-label"></label>
<input asp-for="Nombre" class="form-control" />
<span asp-validation-for="Nombre" class="text-danger"></span>
</div>
<div class="form-group">
<label asp-for="FechaNacimiento" class="control-label"></label>
<input asp-for="FechaNacimiento" class="form-control" type="date" />
<span asp-validation-for="FechaNacimiento" class="text-danger"></span>
</div>
<div class="form-group">
<label asp-for="Semestre" class="control-label"></label>
<input asp-for="Semestre" class="form-control" />
<span asp-validation-for="Semestre" class="text-danger"></span>
</div>
<div class="form-group">
<label asp-for="Foto" class="control-label"></label>
<input name="archivo" id="archivo" type="file" class="form-control" />
</div>
<div class="form-group">
<input type="submit" value="Create" class="btn btn-primary" />
</div>
</form>
</div>
</div>
<div>
<a asp-action="Index">Back to List</a>
</div>
@section Scripts {
@{await Html.RenderPartialAsync("_ValidationScriptsPartial");}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment