Friday, January 3, 2014

How To Use Endpoint Parameter - Flask-Admin

You can access the endpoint parameter by using self.endpoint.

class displayResults(BaseView):
@expose('/',methods=('GET','POST'))
def index(self):
print self.endpoint

admin.add_view(displayResults(name='test', endpoint='test2'))

That will print "test2".

No comments:

Post a Comment