def _resolve(self, context, name):
        parts = name.split('.')

        field = context.resolve(parts[0])

        if not field:
            return None

        for p in parts[1:]:
            field = getattr(field, p, None)

            if not field:
                return field

        return field
Resolve macro in a Jinja2 context
dataset/ETHPy150Open mrjoes/flask-admin/flask_admin/form/rules.py/Macro._resolve