Status post. Django
I think you don't have any idea to solve this issue so here is two:

write a background worker (like celery) run it every few hours and mark old posts as inactive
add a created_at field to your db and instead of marking post as inactive rememvber if created_at is older than 30 days you can't edit/update that post.

I personally prefer second solution because that doesn't need a bacground worker
I created an application where users can add posts. I would like to add the post status. Post after adding has the status "active." After 30 days, changes the status to "inactive" How can I do it?