aw3831: fix yield with decimal
All checks were successful
FarmMaps.Develop/CarbonLib/pipeline/head This commit looks good
All checks were successful
FarmMaps.Develop/CarbonLib/pipeline/head This commit looks good
This commit is contained in:
@@ -8,7 +8,7 @@
|
||||
<GenerateAssemblyConfigurationAttribute>false</GenerateAssemblyConfigurationAttribute>
|
||||
<GenerateAssemblyCompanyAttribute>false</GenerateAssemblyCompanyAttribute>
|
||||
<GenerateAssemblyProductAttribute>false</GenerateAssemblyProductAttribute>
|
||||
<Version>1.1.5</Version>
|
||||
<Version>1.1.6</Version>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
|
||||
@@ -16,7 +16,6 @@ namespace CarbonService.Models
|
||||
[Required]
|
||||
public int PostalCode { get; set; }
|
||||
public List<CropField> CropFields { get; set; }
|
||||
//public List<OrgManureApplied> OrgManureApplied { get; set; }
|
||||
}
|
||||
|
||||
public class CropField
|
||||
@@ -43,10 +42,12 @@ namespace CarbonService.Models
|
||||
|
||||
public class OrgManureApplied
|
||||
{
|
||||
double? yield;
|
||||
|
||||
[Required]
|
||||
public string Crop { get; set; }
|
||||
public List<OrganicManureType> OrganicManures { get; set; }
|
||||
public int? CropYield { get; set; }
|
||||
public double? CropYield { get { return (int?)yield; } set { yield = value; } }
|
||||
public bool CropRes { get; set; }
|
||||
}
|
||||
|
||||
@@ -62,8 +63,6 @@ namespace CarbonService.Models
|
||||
{
|
||||
[Required]
|
||||
public int Year { get; set; }
|
||||
//[Required]
|
||||
//public List<string> Crops { get; set; }
|
||||
[Required]
|
||||
public List<OrgManureApplied> Crops { get; set; }
|
||||
}
|
||||
@@ -81,7 +80,6 @@ namespace CarbonService.Models
|
||||
[Required]
|
||||
public string Type { get; set; }
|
||||
|
||||
//public string Quality { get; set; }
|
||||
[JsonConverter(typeof(StringEnumConverter))]
|
||||
public Quality Quality { get; set; }
|
||||
}
|
||||
|
||||
@@ -9,8 +9,6 @@ namespace FarmMapsAPI.Carbon.Models
|
||||
{
|
||||
[JsonProperty("cropField")]
|
||||
public List<CropFieldSummary> CropField { get; set; }
|
||||
//[JsonProperty("farmSummary")]
|
||||
//public List<FarmYearSummary> FarmSummary { get; set; }
|
||||
}
|
||||
|
||||
public class CropFieldSummary
|
||||
|
||||
@@ -54,11 +54,13 @@ namespace FarmMapsAPI.Carbon.Models
|
||||
|
||||
public class CropData
|
||||
{
|
||||
double? yield;
|
||||
|
||||
[Required]
|
||||
public string CropCode { get; set; }
|
||||
public string MiterraCropName { get; set; }
|
||||
public List<OrganicManureFarmMaps> OrganicManures { get; set; }
|
||||
public int? CropYield { get; set; }
|
||||
public double? CropYield { get { return (int?)yield; } set { yield = value; } }
|
||||
public bool CropRes { get; set; }
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user