Fix generic document view not being usable with querysets