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

25 lines
841 B
C#
Raw Normal View History

2022-07-27 18:14:07 +05:00
using Microsoft.EntityFrameworkCore;
using System;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
using System.Text.Json;
2022-07-27 18:14:07 +05:00
namespace AsbCloudDb.Model
{
[Table("t_user_settings"), Comment("настройки интерфейса пользователя")]
public class UserSetting
{
2022-07-28 10:37:05 +05:00
[Column("id_user")]
2022-07-27 18:14:07 +05:00
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; }
2022-07-27 18:14:07 +05:00
[ForeignKey(nameof(IdUser))]
public User User { get; set; } = null!;
}
}