diff --git a/Controllers/GiriController.cs b/Controllers/GiriController.cs index bc6d13a..35ba858 100644 --- a/Controllers/GiriController.cs +++ b/Controllers/GiriController.cs @@ -265,6 +265,7 @@ namespace SoftwayWeb.Controllers List selectItems = new List(); List modelList = new List(); HttpResponseMessage response = client.GetAsync(baseAddress).Result; + if (response.IsSuccessStatusCode) { string data = response.Content.ReadAsStringAsync().Result; @@ -286,6 +287,7 @@ namespace SoftwayWeb.Controllers selectItems.Add(listItem); } } + return selectItems; } diff --git a/Views/Giri/Index.cshtml b/Views/Giri/Index.cshtml index 814084f..85c7acd 100644 --- a/Views/Giri/Index.cshtml +++ b/Views/Giri/Index.cshtml @@ -26,13 +26,13 @@ @using (Html.BeginForm()) { - @*
@Html.TextBox("codAutista", null, new { placeholder = "Codice autista", @class = "agy-form-field require" })
*@ -
@Html.DropDownList("codAutista", ViewBag.Autisti, null, new { @class = "agy-form-field require" })
-
-
@Html.DropDownList("codMezzo", ViewBag.CodMezzo, null, new { @class = "agy-form-field require" })
-
@Html.TextBox("data", null, new { type = "date", @class = "agy-form-field require" })
-
+
 
+
@Html.DropDownList("codAutista", ViewBag.Autisti, null, new { @class = "agy-form-field require" })
+
 
+
@Html.DropDownList("codMezzo", ViewBag.CodMezzo, null, new { @class = "agy-form-field require" })
+
 
+
@Html.CheckBox("aperto", new { placeholder ="aperto", @checked = true, }) @Html.Label("aperto", "aperto")