I'm trying to understand how overriding the Constructor of a Form (forms.Form or model.Models) allows you to access the Request Object? How does overriding __init__ allow one access to the Request?
I've looked at BaseForm and don't see the Request in the Constructor. So, I don't get it. I thought the Request Object could only be accessed in Views, basically. Any help is greatly appreciated, or a point in the right direction.
Ex:
class MyForm(forms.Form):
def __init__(self, request, *args, **kwargs):
self._my_request = request
super(MyForm, self).__init__(*args, **kwargs)
PS: It;s been years since I've used this group, if I've not posted the question, my apologies.