2024-08-27 16:29:09 +04:00

24 lines
625 B
C#

using ServiceStationDataModels.Models;
using System.ComponentModel;
namespace ServiceStationContracts.ViewModels
{
public class ClientViewModel : IClientModel, IEquatable<ClientViewModel>
{
public int Id { get; set; }
[DisplayName("ФИО")]
public string FIO { get; set; } = string.Empty;
public bool Equals(ClientViewModel? other) {
if (other is null) {
return false;
}
return this.Id == other.Id && this.FIO == other.FIO;
}
public override bool Equals(object obj) => Equals(obj as ClientViewModel);
public override int GetHashCode() => (Id, FIO).GetHashCode();
}
}