mirror of
https://github.com/aaru-dps/Aaru.Server.git
synced 2025-12-16 19:24:27 +00:00
Implement searching reports from device stats.
This commit is contained in:
@@ -346,5 +346,17 @@ namespace DiscImageChef.Server.Areas.Admin.Controllers
|
||||
Id = deviceId
|
||||
});
|
||||
}
|
||||
|
||||
public IActionResult Find(int id, string manufacturer, string model, string revision, string bus)
|
||||
{
|
||||
var found = new FindReportModel
|
||||
{
|
||||
Id = id, Manufacturer = manufacturer, Model = model, Revision = revision,
|
||||
Bus = bus,
|
||||
LikeDevices = _context.Devices.Where(r => r.Model.ToLower().Contains(model.ToLower())).ToList()
|
||||
};
|
||||
|
||||
return View(found);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,4 +1,3 @@
|
||||
using System;
|
||||
using System.Linq;
|
||||
using System.Threading.Tasks;
|
||||
using DiscImageChef.CommonTypes.Metadata;
|
||||
@@ -171,9 +170,6 @@ namespace DiscImageChef.Server.Areas.Admin.Controllers
|
||||
|
||||
bool UploadedReportExists(int id) => _context.Reports.Any(e => e.Id == id);
|
||||
|
||||
public IActionResult Find(int id, string manufacturer, string model, string bus) =>
|
||||
throw new NotImplementedException();
|
||||
|
||||
public IActionResult Promote(int? id)
|
||||
{
|
||||
if(id == null)
|
||||
|
||||
Reference in New Issue
Block a user