forked from wanderer/pwt-0x01-ng
* this still needs to be dealt with server-side, but at least don't present the user a form in which they could edit created/updated fields
46 lines
1.4 KiB
Plaintext
46 lines
1.4 KiB
Plaintext
@model pwt_0x01_ng.Models.OrderItem
|
|
|
|
@{
|
|
ViewData["Title"] = "Edit";
|
|
}
|
|
<h2>@ViewData["Title"]</h2>
|
|
<h3>@ViewData["Message"]</h3>
|
|
|
|
<h4>OrderItem</h4>
|
|
<hr />
|
|
<div class="row">
|
|
<div class="col-md-4">
|
|
<form asp-action="Edit">
|
|
<div asp-validation-summary="ModelOnly" class="text-danger"></div>
|
|
<div class="form-group">
|
|
<label asp-for="Order_id" class="control-label"></label>
|
|
<select asp-for="Order_id" class="form-control" asp-items="ViewBag.Order_id"></select>
|
|
<span asp-validation-for="Order_id" class="text-danger"></span>
|
|
</div>
|
|
<div class="form-group">
|
|
<label asp-for="Product_id" class="control-label"></label>
|
|
<select asp-for="Product_id" class="form-control" asp-items="ViewBag.Product_id"></select>
|
|
<span asp-validation-for="Product_id" class="text-danger"></span>
|
|
</div>
|
|
<div class="form-group">
|
|
<label asp-for="Amount" class="control-label"></label>
|
|
<input asp-for="Amount" class="form-control" />
|
|
<span asp-validation-for="Amount" class="text-danger"></span>
|
|
</div>
|
|
<div class="form-group">
|
|
<label asp-for="Price" class="control-label"></label>
|
|
<input asp-for="Price" class="form-control" />
|
|
<span asp-validation-for="Price" class="text-danger"></span>
|
|
</div>
|
|
<input type="hidden" asp-for="id" />
|
|
<div class="form-group">
|
|
<input type="submit" value="Save" class="btn btn-primary" />
|
|
</div>
|
|
</form>
|
|
</div>
|
|
</div>
|
|
|
|
<div>
|
|
<a asp-action="Index">Back to List</a>
|
|
</div>
|