File size: 982 Bytes
5fc700d | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 | using FreeSql.DataAnnotations;
namespace ToolHub.Models;
[Table(Name = "ToolStatistics")]
public class ToolStatistics
{
[Column(IsIdentity = true, IsPrimary = true)]
public int Id { get; set; }
public int ToolId { get; set; }
public DateTime Date { get; set; } // 统计日期
public int DailyViews { get; set; } = 0; // 日访问量
public int DailyUniqueViews { get; set; } = 0; // 日独立访问量
public int DailyFavorites { get; set; } = 0; // 日收藏数
public int DailyShares { get; set; } = 0; // 日分享数
public int DailyDownloads { get; set; } = 0; // 日下载数
public decimal AverageDuration { get; set; } = 0; // 平均停留时间(秒)
public int BounceCount { get; set; } = 0; // 跳出次数
public DateTime CreatedAt { get; set; } = DateTime.Now;
public DateTime? UpdatedAt { get; set; }
// 导航属性
[Navigate(nameof(ToolId))]
public Tool Tool { get; set; } = null!;
}
|