How can i retrieve the row just entered in database in django -
i used function save data in mysql
form.save()
now want send row can dynamically update table , append row @ bottom. how can retrieve that
if save data mysql using form.save()
use modelform
. modelform save method returns instance of model (row):
row = form.save()
more on this: https://docs.djangoproject.com/en/dev/topics/forms/modelforms/#the-save-method
Comments
Post a Comment