mirror of
https://github.com/Kareadita/Kavita.git
synced 2025-06-03 13:44:31 -04:00
30 lines
792 B
C#
30 lines
792 B
C#
using System;
|
|
using System.Collections;
|
|
using System.Collections.Generic;
|
|
using System.ComponentModel.DataAnnotations;
|
|
using API.Entities.Interfaces;
|
|
|
|
|
|
namespace API.Entities
|
|
{
|
|
public class AppUser : IHasConcurrencyToken
|
|
{
|
|
public int Id { get; set; }
|
|
public string UserName { get; set; }
|
|
public byte[] PasswordHash { get; set; }
|
|
public byte[] PasswordSalt { get; set; }
|
|
public DateTime Created { get; set; } = DateTime.Now;
|
|
public DateTime LastActive { get; set; }
|
|
public bool IsAdmin { get; set; }
|
|
public ICollection<Library> Libraries { get; set; }
|
|
|
|
[ConcurrencyCheck]
|
|
public uint RowVersion { get; set; }
|
|
|
|
public void OnSavingChanges()
|
|
{
|
|
RowVersion++;
|
|
}
|
|
|
|
}
|
|
} |