mirror of
https://github.com/directus/directus.git
synced 2026-04-25 03:00:53 -04:00
Fix relations lookup in m2m/m2a advanced edit existing (#9738)
Fixes #9715
This commit is contained in:
@@ -114,7 +114,8 @@ export const useFieldDetailStore = defineStore({
|
||||
) as DeepPartial<Relation> | undefined;
|
||||
|
||||
if (['files', 'm2m', 'translations', 'm2a'].includes(this.localType)) {
|
||||
this.relations.m2o = relations.find((relation) => relation !== this.relations.o2m) as
|
||||
// These types rely on directus_relations fields being said, so meta should exist for these particular relations
|
||||
this.relations.m2o = relations.find((relation) => relation.meta?.id !== this.relations.o2m?.meta?.id) as
|
||||
| DeepPartial<Relation>
|
||||
| undefined;
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user