摘要: 用上下文处理器app_context_processor定义函数 获取session中保存的值 返回字典 @app.context_processor def mycontext(): usern = session.get('user') if usern: return {'username': usern} else: return... 阅读全文
posted @ 2017-11-24 11:01 袁颖琳 阅读(133) 评论(0) 推荐(0)