Nafiul Islam
Nafiul Islam

Reputation: 82480

What does pre_save and post_save do in django?

I was looking at the documentation here, about pre_save and post_save in django. The documentation really does not provide much substance, so what does pre_save and post_save do?

Upvotes: 0

Views: 224

Answers (1)

arie
arie

Reputation: 18982

You probably skipped the introduction to signals in the docs:

Django includes a “signal dispatcher” which helps allow decoupled applications get notified when actions occur elsewhere in the framework. In a nutshell, signals allow certain senders to notify a set of receivers that some action has taken place.

Let's say you want to create a slug you have basically two options:

Upvotes: 1

Related Questions