fixes
This commit is contained in:
@@ -17,6 +17,7 @@ export function getFieldOptions(field: ResourceField, relationData?: any[]): Sel
|
||||
|
||||
if (field.relation) {
|
||||
const data = Array.isArray(relationData) ? relationData : [];
|
||||
console.log('Getting options for relation', field.relation, 'data count:', data.length);
|
||||
if (data.length === 0) {
|
||||
throw new Error(`Relation data for "${field.relation}" is missing or empty – cannot build options for field "${field.label}"`);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user