Billing: fix calculation

This commit is contained in:
2023-11-02 11:57:38 +01:00
parent 193b4688d3
commit 9f67448b72
20 changed files with 327 additions and 117 deletions

View File

@ -1,8 +1,9 @@
using Microsoft.EntityFrameworkCore;
using System.ComponentModel.DataAnnotations.Schema;
using IndexAttribute = Microsoft.EntityFrameworkCore.IndexAttribute;
namespace Elwig.Models {
[Table("wine_attribute"), PrimaryKey("AttrId")]
[Table("wine_attribute"), PrimaryKey("AttrId"), Index("Name", IsUnique = true)]
public class WineAttr {
[Column("attrid")]
public string AttrId { get; set; }
@ -10,14 +11,18 @@ namespace Elwig.Models {
[Column("name")]
public string Name { get; set; }
[Column("active")]
public bool IsActive { get; set; }
[Column("max_kg_per_ha")]
public int? MaxKgPerHa { get; set; }
[Column("fill_lower_bins")]
public int FillLowerBins { get; set; }
[Column("strict")]
public bool IsStrict { get; set; }
[Column("fill_lower")]
public int FillLower { get; set; }
[Column("active")]
public bool IsActive { get; set; }
public override string ToString() {
return Name;
}