Tested and fixed some things
This commit is contained in:
parent
65a0398444
commit
bbf2db0040
@ -118,7 +118,12 @@ namespace FarmmapsNbs
|
|||||||
var uptakeMapItem =
|
var uptakeMapItem =
|
||||||
await _nitrogenService.CalculateUptakeMap(cropfieldItem, geotiffItem, plantingDate,
|
await _nitrogenService.CalculateUptakeMap(cropfieldItem, geotiffItem, plantingDate,
|
||||||
measurementDate, input.InputVariable);
|
measurementDate, input.InputVariable);
|
||||||
|
if (uptakeMapItem == null)
|
||||||
|
{
|
||||||
|
_logger.LogError("Something went wrong with creating the uptakeMap");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
_logger.LogInformation("Downloading uptake map");
|
_logger.LogInformation("Downloading uptake map");
|
||||||
await _farmmapsApiService.DownloadItemAsync(uptakeMapItem.Code,
|
await _farmmapsApiService.DownloadItemAsync(uptakeMapItem.Code,
|
||||||
Path.Combine(DownloadFolder, $"{input.OutputFileName}.uptake.zip"));
|
Path.Combine(DownloadFolder, $"{input.OutputFileName}.uptake.zip"));
|
||||||
@ -129,6 +134,11 @@ namespace FarmmapsNbs
|
|||||||
measurementDate,
|
measurementDate,
|
||||||
input.InputVariable, targetNData.TargetN);
|
input.InputVariable, targetNData.TargetN);
|
||||||
|
|
||||||
|
if (applicationMapItem == null)
|
||||||
|
{
|
||||||
|
_logger.LogError("Something went wrong with creating the applicationMap");
|
||||||
|
return;
|
||||||
|
}
|
||||||
_logger.LogInformation("Downloading application map");
|
_logger.LogInformation("Downloading application map");
|
||||||
await _farmmapsApiService.DownloadItemAsync(applicationMapItem.Code,
|
await _farmmapsApiService.DownloadItemAsync(applicationMapItem.Code,
|
||||||
Path.Combine(DownloadFolder, $"{input.OutputFileName}.application.zip"));
|
Path.Combine(DownloadFolder, $"{input.OutputFileName}.application.zip"));
|
||||||
|
Loading…
Reference in New Issue
Block a user