I have following problem in AX
Background:
- two tables A and B, relation A:B is 1:N, B contains reference to A.recId
- dataSource B joins dataSource A using Active join
- both datasources are displayed in their own grids (records displayed in grid B are related to record selected in grid A)
Desired behavior:
- I want to prohibit creation of new records in B if there are no records selected or existing in A, because otherwise I won't have the relation created correctly
I assume I can put code responsible for it into init() method of dataSource B and active method of dataSource A, but isn't there a way to achieve this behavior more elegantly?