Fixed spatial issues with finding map cuts data.
This commit is contained in:
@@ -383,8 +383,8 @@ class CutsController {
|
||||
return res.status(404).json({ error: 'Cut not found' });
|
||||
}
|
||||
|
||||
// Get all locations
|
||||
const locationsResponse = await nocodbService.getAll(config.LOCATIONS_TABLE_ID);
|
||||
// Get all locations (use paginated to get ALL records, not just first page)
|
||||
const locationsResponse = await nocodbService.getAllPaginated(config.LOCATIONS_TABLE_ID);
|
||||
if (!locationsResponse || !locationsResponse.list) {
|
||||
return res.json({ locations: [], statistics: { total_locations: 0 } });
|
||||
}
|
||||
@@ -448,8 +448,8 @@ class CutsController {
|
||||
return res.status(403).json({ error: 'Export is disabled for this cut' });
|
||||
}
|
||||
|
||||
// Get all locations
|
||||
const locationsResponse = await nocodbService.getAll(config.LOCATIONS_TABLE_ID);
|
||||
// Get all locations (use paginated to get ALL records, not just first page)
|
||||
const locationsResponse = await nocodbService.getAllPaginated(config.LOCATIONS_TABLE_ID);
|
||||
if (!locationsResponse || !locationsResponse.list) {
|
||||
return res.json({ locations: [] });
|
||||
}
|
||||
@@ -586,8 +586,8 @@ class CutsController {
|
||||
return res.status(404).json({ error: 'Cut not found' });
|
||||
}
|
||||
|
||||
// Get all locations
|
||||
const locationsResponse = await nocodbService.getAll(config.LOCATIONS_TABLE_ID);
|
||||
// Get all locations (use paginated to get ALL records, not just first page)
|
||||
const locationsResponse = await nocodbService.getAllPaginated(config.LOCATIONS_TABLE_ID);
|
||||
if (!locationsResponse || !locationsResponse.list) {
|
||||
return res.json({
|
||||
statistics: { total_locations: 0 },
|
||||
|
||||
Reference in New Issue
Block a user