I have three content types,
Event has entity references to
Championship has an entity reference to
----- 1..n 1..n ------------ |Event|------------|Championship| ----- ------------ |0..n |0..n | | | | |1..n | ---------- 1 | |Discipline|-----------/ ----------
When users are creating new
Event nodes they initially select which
Disciplines are involved from a list of checkboxes and then similarly the
At the moment all
Championships nodes appear, allowing users to potentially select
Disciplines which are not part of the
Is it possible to use the conditional fields module to create a dependency to display only
Championships where the
Championship's Discipline field matches the
Discipline(s) selected when the dependency is triggered?
How would one fill the 'Set of values' in the conditional fields module?
For example when creating
Event1, I select
DisciplineB. The list of
Championships should only contain those which have
DisciplineB associations and not contain any
Championships that do not have the correct associations
if event.disciplines were a list of selected disciplines I'd like something along these lines (with the dynamic aspects of conditional fields)
SELECT championships c WHERE c.discipline IN (event.disciplines)
Dependent Fields seems to do the sort of thing i'd like but there's no D7 version...
Changed the structure a little.
Discipline didn't need to be an entity in itself and have created a taxonomy vocabulary Discipline instead with terms for each discipline.
Championship now have term references to the same
Using the Reference field limit option module the
Championship entity reference in
Event has the 'Limit this field's options according to the matching field values' option selected and the matching field being
When creating an
Event the list of
Championships is empty but when I select the
Discipline(s) the expected
Championships do not appear.
No options are available for the current form values. Try selecting different values for the following fields: discipline.
Firebug suggested that the ajax wasn't actually firing for checkbox/radio button but was for select menu. Applied this patch and the section is now updating but still not finding any values. There are appropriate
Championship nodes to find.
Championship nodes didn't have the discipline taxonomies selected...