fix(parcel-sync): allow DB download regardless of layer freshness
The top export buttons required all primary layers to be "fresh" (<7 days) before using the DB download path. When stale, they fell through to live eTerra sync which requires credentials — blocking users who just want to download existing data. Now any UAT with data in DB uses the local export path directly. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -149,10 +149,8 @@ export function ExportTab({
|
||||
const primaryLayers = dbLayersSummary.filter((l) =>
|
||||
PRIMARY_LAYERS.includes(l.id),
|
||||
);
|
||||
const allFresh =
|
||||
primaryLayers.length > 0 && primaryLayers.every((l) => l.isFresh);
|
||||
const hasData = dbTotalFeatures > 0;
|
||||
const canExportLocal = allFresh && hasData;
|
||||
const canExportLocal = hasData;
|
||||
|
||||
const oldestSyncDate = primaryLayers.reduce(
|
||||
(oldest, l) => {
|
||||
|
||||
Reference in New Issue
Block a user