- I have a behavior schema for a Dexterity type license.
- it has two fields year and person-number - both in catalog
- I want to test if a combination of these two values already exists under my current folder.
@invariant def check_combination_exists(data) ....
Plan is to query the catalog with year, person-number and path of the current folder. If there is result, the invariant fails.
Problem: I have no context in there, only a
data.__context__ is None in an add-form as it seems.
Any ideas how to get the add-context of an add-form in the invariant?