我有一个这样定义的视图:
@views.route('/issues')
def show_view():
action = request.args.get('action')
method = getattr(process_routes, action)
return method(request.args)
在我的 process_routes 模块中,我想调用这个方法,并传递查询字符串值。我有以下代码:
return redirect(url_for('views.show_view', action='create_or_update_success'))
我在 process_routes 中有一个名为 create_or_update_success 的函数
我正进入(状态
BuildError: ('views.show_view', {'action': 'create_or_update_success'}, None)
意见是一个蓝图。我可以成功调用
/issues?action=create_or_update_success
在我的浏览器中。
我究竟做错了什么?