Pass your database model into the constructor of BobbyViews and access it via self.