[myweb@am_01 PonyTail]$ pwd /home/myweb/PonyTail [myweb@am_01 PonyTail]$ ll total 8 -rw-rw-r--. 1 myweb myweb 1 Nov 2 18:33 __init__.py -rw-rw-r--. 1 myweb myweb 1743 Nov 2 19:19 manage.py drwxrwxr-x. 2 myweb myweb 63 Nov 2 17:32 templates
修改后manage.py文件如下:
# -*- coding:utf8 -*-
from flask import Flask from flask_admin import Admin from flask_admin import BaseView from flask_admin import expose from flask_babelex import Babel # 06_展示数据库表单新增 from flask_sqlalchemy import SQLAlchemy from flask_admin.contrib.sqla import ModelView
[myweb@am_01 PonyTail]$ python manage.py * Serving Flask app "manage" (lazy loading) * Environment: production WARNING: Do not use the development server in a production environment. Use a production WSGI server instead. * Debug mode: on * Running on http://0.0.0.0:5000/ (Press CTRL+C to quit) * Restarting with stat * Debugger is active! * Debugger PIN: 476-676-292