31 lines
		
	
	
		
			845 B
		
	
	
	
		
			C#
		
	
	
	
	
	
			
		
		
	
	
			31 lines
		
	
	
		
			845 B
		
	
	
	
		
			C#
		
	
	
	
	
	
using Microsoft.EntityFrameworkCore;
 | 
						|
using System.ComponentModel.DataAnnotations.Schema;
 | 
						|
using IndexAttribute = Microsoft.EntityFrameworkCore.IndexAttribute;
 | 
						|
 | 
						|
namespace Elwig.Models.Entities {
 | 
						|
    [Table("wine_attribute"), PrimaryKey("AttrId"), Index("Name", IsUnique = true)]
 | 
						|
    public class WineAttr {
 | 
						|
        [Column("attrid")]
 | 
						|
        public required string AttrId { get; set; }
 | 
						|
 | 
						|
        [Column("name")]
 | 
						|
        public required string Name { get; set; }
 | 
						|
 | 
						|
        [Column("active")]
 | 
						|
        public bool IsActive { get; set; }
 | 
						|
 | 
						|
        [Column("max_kg_per_ha")]
 | 
						|
        public int? MaxKgPerHa { get; set; }
 | 
						|
 | 
						|
        [Column("strict")]
 | 
						|
        public bool IsStrict { get; set; }
 | 
						|
 | 
						|
        [Column("fill_lower")]
 | 
						|
        public int FillLower { get; set; }
 | 
						|
 | 
						|
        public override string ToString() {
 | 
						|
            return Name;
 | 
						|
        }
 | 
						|
    }
 | 
						|
}
 |