filtro data
This commit is contained in:
parent
1219ed236c
commit
cf4fc2c05b
@ -23,7 +23,7 @@ namespace SoftwayWeb.Controllers
|
||||
apiUrl = key;
|
||||
}
|
||||
|
||||
public IActionResult Index(string? codAutista, DateTime? data, bool aperto = true)
|
||||
public IActionResult Index(string? codAutista, DateTime data, bool aperto = true)
|
||||
{
|
||||
helper = new SessionHelper(this);
|
||||
token = helper.GetStringValue("tok");
|
||||
@ -51,6 +51,11 @@ namespace SoftwayWeb.Controllers
|
||||
{
|
||||
ViewData["CurrentFilter"] = null;
|
||||
}
|
||||
|
||||
if (data.Date != DateTime.MinValue)
|
||||
{
|
||||
modelList = modelList.Where(x => x.DataGiro.GetValueOrDefault().Date == data.Date).ToList();
|
||||
}
|
||||
//var shortList = modelList.ToPagedList();
|
||||
return View(modelList);
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user