modified views.py to add button interaction