Created
February 8, 2018 13:00
-
-
Save tusmester/494d5864f36d97e71c666134e44689ff to your computer and use it in GitHub Desktop.
#sn #mvc #view #deletetask
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@{ | |
ViewBag.Title = "Delete task"; | |
ViewBag.Message = "Are you sure you want to delete this task?"; | |
} | |
@using SnWebApplication.Models | |
@model TaskViewModel | |
<h2>@ViewBag.Title</h2> | |
<h3>@ViewBag.Message</h3> | |
<div class="row"> | |
<div class="col-md-8"> | |
<section id="loginForm"> | |
@using (Html.BeginRouteForm("Default", new RouteValueDictionary | |
{ | |
{"controller", "Dashboard"}, | |
{"action", "Delete"}, | |
{ "Id", Model.Id } | |
}, FormMethod.Post, new { @class = "form-horizontal", role = "form" })) | |
{ | |
@Html.AntiForgeryToken() | |
<div class="form-group"> | |
@Html.LabelFor(m => m.DisplayName, new { @class = "col-md-2 control-label" }) | |
<div class="col-md-10"> | |
@Model.DisplayName | |
</div> | |
</div> | |
<div class="form-group"> | |
@Html.LabelFor(m => m.AssignedToText, new { @class = "col-md-2 control-label" }) | |
<div class="col-md-10"> | |
@Model.AssignedToText | |
</div> | |
</div> | |
<div class="form-group"> | |
<div class="col-md-offset-2 col-md-10"> | |
<input type="submit" value="Delete" class="btn btn-default" /> | |
@Html.MvcActionLink("Cancel", "Index", "Dashboard") | |
</div> | |
</div> | |
} | |
</section> | |
</div> | |
</div> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment