29 lines
894 B
C#
29 lines
894 B
C#
using InboxIntel.Domain.Common;
|
|
|
|
namespace InboxIntel.Domain.Entities;
|
|
|
|
/// <summary>
|
|
/// Persisted dashboard layout for a user. One row per widget instance,
|
|
/// storing grid geometry and visibility so the dashboard restores exactly.
|
|
/// </summary>
|
|
public class WidgetLayout : AuditableEntity
|
|
{
|
|
public Guid Id { get; set; } = Guid.NewGuid();
|
|
public Guid UserId { get; set; }
|
|
|
|
/// <summary>Stable widget key, e.g. "inbox-health", "top-senders".</summary>
|
|
public string WidgetKey { get; set; } = string.Empty;
|
|
|
|
// react-grid-layout geometry.
|
|
public int X { get; set; }
|
|
public int Y { get; set; }
|
|
public int W { get; set; } = 4;
|
|
public int H { get; set; } = 4;
|
|
|
|
public bool Visible { get; set; } = true;
|
|
public int SortOrder { get; set; }
|
|
|
|
/// <summary>Optional per-widget settings as JSON.</summary>
|
|
public string? SettingsJson { get; set; }
|
|
}
|