update poten; schaduw moet nu als attribute worden meegegeven

This commit is contained in:
2021-03-09 14:15:32 +01:00
parent 761221d936
commit f71f072be7
6 changed files with 65 additions and 51 deletions

View File

@@ -64,11 +64,12 @@ namespace FarmmapsApi.Services
}
public async Task<Item> ShapeToGeotiff(Item shapeItem) {
var startUpload = DateTime.UtcNow.AddSeconds(-3);
await RunAndWaitForTask(shapeItem, "vnd.farmmaps.task.shapetogeotiff");
// the parent of the shape item is now the tiff item
shapeItem = await _farmmapsApiService.GetItemAsync(shapeItem.Code);
return await _farmmapsApiService.GetItemAsync(shapeItem.ParentCode);
return await FindChildItemAsync(shapeItem.ParentCode, GEOTIFF_PROCESSED_ITEMTYPE, shapeItem.Name,
i => i.Created >= startUpload &&
i.Name.ToLower().Contains(shapeItem.Name.ToLower()));
}