using System.ComponentModel.DataAnnotations;

namespace Silk_Road_Api.ViewModels;

public class DrugViewModel
{
    public int id { get; set; } = 0;
    [RegularExpression(@"^[a-zA-Z''-'\s]{3,40}$", ErrorMessage = "Characters are not allowed.")]
    public string name { get; set; }
    [Range(0, 999.99)]
    public decimal price { get; set; }
    [Range(0, 20000)]
    public int stock { get; set; }
    [RegularExpression(@"^[a-zA-Z''-'\s]{3,40}$", ErrorMessage = "Characters are not allowed.")]
    public string description { get; set; }
    [RegularExpression(@"^[a-zA-Z''-'\s]{3,40}$", ErrorMessage = "Characters are not allowed.")]
    public string manufacturer { get; set; }
    [RegularExpression(@"^[a-zA-Z''-'\s]{3,40}$", ErrorMessage = "Characters are not allowed.")]
    public string sideEffects { get; set; }
    [RegularExpression(@"^[a-zA-Z''-'\s]{3,40}$", ErrorMessage = "Characters are not allowed.")]
    public string interactions { get; set; }
    [RegularExpression(@"^[a-zA-Z''-'\s]{3,40}$", ErrorMessage = "Characters are not allowed.")]
    public string dosage { get; set; }
    [RegularExpression(@"^[a-zA-Z''-'\s]{3,40}$", ErrorMessage = "Characters are not allowed.")]
    public string contraindications { get; set; }
    [RegularExpression(@"^[a-zA-Z''-'\s]{3,40}$", ErrorMessage = "Characters are not allowed.")]
    public string warnings { get; set; }
    [RegularExpression(@"^[a-zA-Z''-'\s]{3,40}$", ErrorMessage = "Characters are not allowed.")]
    public string storage { get; set; }
    [RegularExpression(@"^[a-zA-Z''-'\s]{3,40}$", ErrorMessage = "Characters are not allowed.")]
    public string pregnancy { get; set; }
    [RegularExpression(@"^[a-zA-Z''-'\s]{3,40}$", ErrorMessage = "Characters are not allowed.")]
    public string breastfeeding { get; set; }
    [RegularExpression(@"^[a-zA-Z''-'\s]{3,40}$", ErrorMessage = "Characters are not allowed.")]
    public string overdose { get; set; }
}
