django filter validation code example
Example 1: filter field set in django formds
if request.method == "POST":
modelform = AgregarProducto(request.POST, request.FILES, user=request.user)
...
else:
modelform = AgregarProducto(user=request.user)
Example 2: filter field set in django formds
from django.contrib.auth.decorators import login_required
@login_required
def agregar_producto(request):