DD.WellWorkover.Cloud/AsbCloudDb/Model/UserSetting.cs

25 lines
838 B
C#

using Microsoft.EntityFrameworkCore;
using System;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
using System.Text.Json;
namespace AsbCloudDb.Model
{
[Table("t_user_settings"), Comment("настройки интерфейса пользователя")]
public class UserSetting
{
[Column("id_user")]
public int IdUser { get; set; }
[Column("key"), Comment("Ключ настроек пользователя"), StringLength(255)]
public string Key { get; set; } = null!;
[Column("setting_value", TypeName = "jsonb"), Comment("Значение настроек пользователя")]
public JsonDocument? Value { get; set; }
[ForeignKey(nameof(IdUser))]
public User User { get; set; } = null!;
}
}