Set Url kwargs to view
class ProcessUrl(object):
'''
A mixin for class based views to set kwargs from url pattern to view
'''
def dispatch(self, *args, **kwargs):
for key, value in self.kwargs.items():
setattr(self, key, value)
return super(ProcessUrl, self).dispatch(*args, **kwargs)