Fix wizard showing after validation error
This commit is contained in:
parent
f809cdcab0
commit
7bbb480ae2
@ -47,7 +47,7 @@
|
||||
<div class="pkg_meta">{{ render_submit_field(form.submit) }}</div>
|
||||
</form>
|
||||
|
||||
{% if not package.title %}
|
||||
{% if enable_wizard %}
|
||||
<script src="/static/jquery.min.js"></script>
|
||||
<script src="/static/url.min.js"></script>
|
||||
<script src="/static/polltask.js"></script>
|
||||
|
@ -191,7 +191,9 @@ def create_edit_package_page(author=None, name=None):
|
||||
|
||||
return redirect(package.getDetailsURL())
|
||||
|
||||
return render_template("packages/create_edit.html", package=package, form=form, author=author)
|
||||
enableWizard = name is None and request.method != "POST"
|
||||
return render_template("packages/create_edit.html", package=package, \
|
||||
form=form, author=author, enable_wizard=enableWizard)
|
||||
|
||||
@app.route("/packages/<author>/<name>/approve/", methods=["POST"])
|
||||
@login_required
|
||||
|
Loading…
x
Reference in New Issue
Block a user