forked from FarmMaps/FarmMapsApiClient
Added ability to query for herbicide agents.
This commit is contained in:
@@ -30,25 +30,6 @@ namespace FarmmapsHerbicide
|
||||
_farmmapsApiService = farmmapsApiService;
|
||||
_generalService = generalService;
|
||||
_herbicideService = herbicideService;
|
||||
|
||||
_liberatorTarweAgent = new HerbicideAgent()
|
||||
{
|
||||
Name = "Liberator",
|
||||
SoilType = "Klei",
|
||||
ExtraInputType = "OrganicMatter",
|
||||
ActiveSubstanceContent = "diflu100+flufenacet400",
|
||||
MinDosis = 0.33f,
|
||||
MaxDosis = 0.6f,
|
||||
A = 0.007f,
|
||||
B = 0.25f,
|
||||
C = 1.05f,
|
||||
D = 97f,
|
||||
E = 3f,
|
||||
P = 1f,
|
||||
Crop = "Tarwe",
|
||||
Description = "Org. stof arme grond",
|
||||
TankMix = string.Empty
|
||||
};
|
||||
}
|
||||
|
||||
public async Task RunAsync()
|
||||
@@ -59,6 +40,9 @@ namespace FarmmapsHerbicide
|
||||
// !! this call is needed the first time an api is called with a fresh clientid and secret !!
|
||||
await _farmmapsApiService.GetCurrentUserCodeAsync();
|
||||
var roots = await _farmmapsApiService.GetCurrentUserRootsAsync();
|
||||
|
||||
var agents = await _herbicideService.GetHerbicideAgents();
|
||||
_liberatorTarweAgent = agents.SingleOrDefault(a => a.Name.Equals("Liberator"));
|
||||
|
||||
await SingleLutumTiffFlow(roots);
|
||||
await MultiVanDenBorneShapeFlow(roots);
|
||||
|
Reference in New Issue
Block a user