@model ProductDto

<form asp-action="ProductEdit">
    <br />
    <div class="container border p-3">
        <h1 class="text-white text-center">Edit Product</h1>
        <input type="hidden" asp-for="Id" value="@Model.Id"/>
        <hr />
        <div class="row">
            <div class="col-10">
                <div class="row">
                    <div class="col-2">
                        <label class="control-label pt-2" style="font-size:20px;"> Name</label>
                    </div>
                    <div class="col-10 pb-3">
                        <input asp-for="Name" class="form-control" />
                        <span asp-validation-for="Name" class="text-danger"></span>
                    </div>
                    <div class="col-2">
                        <label class="control-label pt-2" style="font-size:20px;">Category Name</label>
                    </div>
                    <div class="col-10 pb-3">
                        <input asp-for="Category" class="form-control" />
                        <span asp-validation-for="Category" class="text-danger"></span>
                    </div>
                    <div class="col-2">
                        <label class="control-label pt-2" style="font-size:20px;">Description</label>
                    </div>
                    <div class="col-10 pb-3">
                        <textarea asp-for="Description" class="form-control" rows="5"></textarea>
                        <span asp-validation-for="Description" class="text-danger"></span>
                    </div>
                    <div class="col-2">
                        <label class="control-label pt-2" style="font-size:20px;">Price</label>
                    </div>
                    <div class="col-10 pb-3">
                        <input asp-for="Price" class="form-control" />
                        <span asp-validation-for="Price" class="text-danger"></span>
                    </div>
                    @*<div class="col-2">
                    <label class="control-label pt-2" style="font-size:20px;">ImageUrl</label>
                    </div>
                    <div class="col-10 pb-3">
                    <input asp-for="Image" class="form-control" />
                    <input asp-for="ImageUrl" hidden class="form-control" />
                    <input asp-for="ImageLocalPath" hidden class="form-control" />
                    <span asp-validation-for="Image" class="text-danger"></span>
                    </div>
                    *@
                    <div class="col-5 offset-2">

                        <a asp-action="ProductIndex" class="btn-primary btn form-control ">Back to List</a>
                    </div>
                    <div class="col-5">
                        <input type="submit" value="Update" class="btn btn-success form-control" />
                    </div>

                </div>
            </div>
            @* <div class="col-2">
                <img src="@Model.ImageUrl" class="w-100" alt="" />
            </div> *@
        </div>
    </div>
</form>


@section Scripts {
    <partial name="_ValidationScriptsPartial" />
}