Files
WatchIt/WatchIt.Common/WatchIt.Common.Model/Accounts/AccountProfileInfoRequest.cs

42 lines
850 B
C#
Raw Normal View History

2024-10-26 02:23:33 +02:00
using System.Text.Json.Serialization;
namespace WatchIt.Common.Model.Accounts;
public class AccountProfileInfoRequest
2024-10-26 02:23:33 +02:00
{
#region PROPERTIES
[JsonPropertyName("description")]
public string? Description { get; set; }
2024-10-26 02:23:33 +02:00
[JsonPropertyName("gender_id")]
public short? GenderId { get; set; }
2024-10-26 02:23:33 +02:00
#endregion
#region CONSTRUCTORS
public AccountProfileInfoRequest() { }
public AccountProfileInfoRequest(AccountResponse accountResponse)
{
Description = accountResponse.Description;
GenderId = accountResponse.Gender?.Id;
}
#endregion
2024-10-26 02:23:33 +02:00
#region PUBLIC METHODS
public void UpdateAccount(Database.Model.Account.Account account)
{
account.Description = Description;
account.GenderId = GenderId;
}
#endregion
}