0

Is it any chance to implement recovery of the deleted model objects by django-reversion from a site web page or it works only from admin panel? I dont wait for ready solution, rather i need to know if it possible or not or maybe some advice where i need to dig to find information about how to do it.

Sorry for the broad question.

Thanks.

Aleksei Khatkevich
  • 1,923
  • 2
  • 10
  • 27

1 Answers1

0

Yes, it is possible by fullfiling following code in the view;

versions = Version.objects.get_for_model(NameofYourmodel).filter(object_id=someid) 
versions[0].revision.revert()

Aleksei Khatkevich
  • 1,923
  • 2
  • 10
  • 27