get_fields_from_path
Return list of Fields given path relative to model.
def get_fields_from_path(
model: Model,
path: str
) - > list
Return list of Fields given path relative to model.
Parameters
| Name | Type | Description |
|---|---|---|
| model | Model | The starting Django model class from which the path traversal begins. |
| path | str | A string representing the relationship path using double-underscore separators (e.g., 'user__groups__name'). |
Returns
| Type | Description |
|---|---|
list | A list of Django Field objects representing each segment of the lookup path. |