I found the answer in the documentation: http://flask-admin.readthedocs.org/en/latest/api/mod_base/
It can be overridden by passing your own view class to the Admin constructor:
class MyHomeView(AdminIndexView):
@expose('/')
def index(self):
arg1 = 'Hello'
return self.render('admin/myhome.html', arg1=arg1)
admin = Admin(index_view=MyHomeView())
Also, you can change the root url from /admin to / with the following:
admin = Admin(
app,
index_view=AdminIndexView(
name='Home',
template='admin/myhome.html',
url='/'
)
)
Default values for the index page are:
- If a name is not provided, ‘Home’ will be used.
- If an endpoint is not provided, will default to admin Default URL route is /admin.
- Automatically associates with static folder. Default template is admin/index.html