You can do it by with the help of form.save().
For example,
from django.shortcuts import render
from django.http import HttpResponse, HttpResponseRedirect
from .forms import EmpDetailForm
def addEmp(request):
if request.method == 'POST':
empform = EmpDetailForm(request.POST)
if empform.is_valid():
Hi All,
I had created a class based model with attributes.
The first migration went well and I could see the table in database
(postgres).
However, when I modified the model, the migration is unable to pick the
changes.
Any inputs would be highly appreciated.
Thanks,
Roshan | zaaroshan0...@gm
2 matches
Mail list logo