I removed 'default' attribute and replaced OneToOneField with ForeignKey of
Post Model still it is not saving to database.
Do I need to override the save method as I did in Category Model.
If yes,then any solution??
On Tuesday, June 28, 2016 at 5:44:16 PM UTC+5:30, kaustubh tripathi wrote:
>
> H
models.OneToOneField(Category,default='category')
This is not set in form and not set in view and is not null so when you do
post.save() error was raised and post is not saved.
I don't sure that you can pass str as default for OnetoOne and I am not
sure that you need a OnetoOne field I think fore
2 matches
Mail list logo