mirror of
https://github.com/claunia/romrepomgr.git
synced 2025-12-16 19:24:51 +00:00
Cache statistics and move its generation to importers.
This commit is contained in:
@@ -40,8 +40,9 @@ namespace RomRepoMgr.Database.Models
|
||||
[Required]
|
||||
public string Filename { get; set; }
|
||||
[Required, StringLength(96, MinimumLength = 96)]
|
||||
public string Sha384 { get; set; }
|
||||
public string Category { get; set; }
|
||||
public string Sha384 { get; set; }
|
||||
public string Category { get; set; }
|
||||
public virtual RomSetStat Statistics { get; set; }
|
||||
|
||||
public virtual ICollection<Machine> Machines { get; set; }
|
||||
}
|
||||
|
||||
17
RomRepoMgr.Database/Models/RomSetStat.cs
Normal file
17
RomRepoMgr.Database/Models/RomSetStat.cs
Normal file
@@ -0,0 +1,17 @@
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
|
||||
namespace RomRepoMgr.Database.Models
|
||||
{
|
||||
public class RomSetStat
|
||||
{
|
||||
public long TotalMachines { get; set; }
|
||||
public long CompleteMachines { get; set; }
|
||||
public long IncompleteMachines { get; set; }
|
||||
public long TotalRoms { get; set; }
|
||||
public long HaveRoms { get; set; }
|
||||
public long MissRoms { get; set; }
|
||||
public virtual RomSet RomSet { get; set; }
|
||||
[Key]
|
||||
public long RomSetId { get; set; }
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user