Update views.py

This is test code. It returns the expected results, but it is just a sketch to test a few ideas.