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