Hello everyone
I tried to override "RichTextPageAdmin" to use the *save_model* and 
*delete_model* methods when creates or deleted RichText type pages. The 
code would be something like this

class RichTextPageAdmin(PageAdmin):

    def delete_model(self, request, obj):
        # do something
        return PageAdmin.delete_model(self, request, obj)

    def save_model(self, request, obj, form, change):
        # do something
        return PageAdmin.save_model(self, request, obj, form, change)

if RichTextPage in admin.site._registry:
    admin.site.unregister(RichTextPage)
admin.site.register(RichTextPage, RichTextPageAdmin)

So, when I saw that the test worked only with the save_model method, I 
noticed that the delete_model method does not exist in the PageAdmin class.
So I'm wondering, how can I execute a code when a RichText type page is 
deleted?

-- 
You received this message because you are subscribed to the Google Groups 
"Mezzanine Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to