title: get current user in form
body: <p>im trying to get current login user in form field using ForeignKey , but im  getting dropdown menu with list all users in database</p>
  
  <p>view.py </p>
  
  <pre><code>@login_required
  def user_request(request):
  
      if request.method == 'POST':
          form = UserRequest(request.POST or None)
  
          if form.is_valid():
              data = form.save(commit=False)
              data.user = request.user
              form.save()
              messages.success(request, 'Success')
              return redirect('home')
      else:
          form = UserRequest()
          print(form)
      context = {
          'form': form,
      }
  
      return render(request, 'users/request.html', context)
  </code></pre>
  
  <p>models.py</p>
  
  <pre><code>class UserRequestModel(models.Model):
      user = models.ForeignKey(User, on_delete=models.CASCADE)
      product_id = models.FloatField()
      email = models.EmailField()
      status = models.CharField(default='Pending', max_length=20)
      date = models.DateField()
      created_at = models.DateTimeField(auto_now=True)
      updated_at = models.DateTimeField(auto_now_add=True)
  
      def __str__(self):
          return self.user
  </code></pre>
  
  <p>form.py</p>
  
  <pre><code>class UserRequestForm(forms.ModelForm):
  
      class Meta:
          model = UserRequestModel
          fields = ['user']
  
  
  class UserRequest(UserRequestForm):
      date = forms.DateField()
      product_id = forms.IntegerField()
  
      class Meta(UserRequestForm.Meta):
          fields = UserRequestForm.Meta.fields + ['date', 'product_id']
  </code></pre>
  
  <p>what im missing to get current user in form field instead of all users list?</p>