fiz um monte de coisa e criei um bug

This commit is contained in:
2025-01-15 11:04:27 -03:00
parent a2fd5d12e3
commit 43d9cd9c5b
20 changed files with 83 additions and 19 deletions

View File

@@ -40,7 +40,7 @@ def createComanda(request):
name = request.POST.get('name-comanda')
mesa_id = int(request.POST.get('select-mesa')[0])
mesa = Mesa.objects.get(id=mesa_id)
comanda = Comanda(name=name, mesa=mesa)
comanda = Comanda(name=name, mesa=mesa, user=request.user)
comanda.save()
return redirect('comandas')