gestione messaggio errore login. Modifiche per flag giri aperti chiusi.
This commit is contained in:
parent
d896ef9831
commit
9ffdb91fba
@ -101,6 +101,8 @@ namespace SoftwayWeb.Controllers
|
||||
page = 1;
|
||||
}
|
||||
|
||||
ViewData["Aperto"] = aperto;
|
||||
|
||||
var pageSize = 10;
|
||||
|
||||
var shortList = modelList.ToPagedList(page ?? 1, pageSize);
|
||||
|
||||
@ -63,6 +63,9 @@ namespace SoftwayWeb.Controllers
|
||||
{
|
||||
errMes = response.Content.ReadAsStringAsync().Result;
|
||||
loginOut = JsonConvert.DeserializeObject<Login_Out>(errMes);
|
||||
|
||||
helper.SetStringValue("errMsg", loginOut.err_detail);
|
||||
ViewBag.Error = loginOut.err_detail;
|
||||
return View();
|
||||
}
|
||||
//return View(model);
|
||||
|
||||
@ -46,8 +46,12 @@
|
||||
</td>
|
||||
<td>
|
||||
|
||||
@Html.CheckBox("aperto", new { placeholder ="aperto" , @checked = true})
|
||||
@Html.Label("aperto", "aperto")
|
||||
@* @Html.CheckBox("aperto", new { placeholder ="aperto" , @checked = true})
|
||||
@Html.Label("aperto", "aperto") *@
|
||||
|
||||
@* questa istruzione sostituisce quella sopra così mantiene il valore del check non rimettendolo a true quando cambio pagina *@
|
||||
@Html.CheckBox("aperto", ViewData["Aperto"] != null && (bool)ViewData["Aperto"] ? new { @checked = "checked" } : null)
|
||||
@Html.Label("aperto", "Aperto")
|
||||
|
||||
</td>
|
||||
<td>
|
||||
@ -175,11 +179,8 @@
|
||||
|
||||
<!--/ Striped Rows -->
|
||||
|
||||
|
||||
|
||||
|
||||
<nav>
|
||||
@Html.PagedListPager(Model, page => Url.Action("index", new { page = page, searchString = @ViewData["CurrentFilter"] }), new PagedListRenderOptions()
|
||||
@Html.PagedListPager(Model, page => Url.Action("index", new { page = page, searchString = @ViewData["CurrentFilter"], aperto = ViewData["Aperto"] }), new PagedListRenderOptions()
|
||||
{
|
||||
ActiveLiElementClass = "active",
|
||||
PageClasses = new[] { "page-link" },
|
||||
|
||||
@ -30,51 +30,15 @@
|
||||
<button type="submit" class="btn btn-primary">Entra</button>
|
||||
</form>
|
||||
</div>
|
||||
<div class="row" style="float:left;width:100%">
|
||||
<div class="col-md-6" style="color:red;">
|
||||
@ViewBag.Error
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div style="float:left;width:25%"> </div>
|
||||
|
||||
|
||||
<div style="float:left;width:35%"> </div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
@*<div class="col-lg-8 col-md-12 col-sm-12 col-12">
|
||||
<div class="agy-contact-form">
|
||||
|
||||
<form asp-action="Login">
|
||||
<div asp-validation-summary="ModelOnly" class="text-danger"></div>
|
||||
<div class="row">
|
||||
<div class="col-lg-6 col-md-6 col-sm-12 col-12">
|
||||
<div class="agy-field-holder">
|
||||
<input asp-for="username" class="agy-form-field require" placeholder="Username" />
|
||||
<span asp-validation-for="username" class="text-danger"></span>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-lg-6 col-md-6 col-sm-12 col-12"> </div>
|
||||
<br />
|
||||
<br />
|
||||
<div class="col-lg-6 col-md-6 col-sm-12 col-12">
|
||||
<div class="agy-field-holder">
|
||||
<input asp-for="password" class="agy-form-field require" placeholder="Password" />
|
||||
<span asp-validation-for="password" class="text-danger"></span>
|
||||
</div>
|
||||
</div>
|
||||
<br />
|
||||
<br />
|
||||
|
||||
<div class="col-lg-12 col-md-12 col-sm-12 col-12">
|
||||
<input type="submit" value="Login" class="agy-btn submitForm" />
|
||||
<div class="response"></div>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</div>*@
|
||||
<div class="row">
|
||||
<div class="col-md-4" style="color:red;">
|
||||
@ViewBag.Error
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user