Ejemplo n.º 1
0
    def post(self):
        form = AddGroupForm()
        if form.validate_on_submit():
            form.save()
            flash(_('Group added.'), 'success')
            return redirect(url_for('management.groups'))

        return render_template('management/group_form.html', form=form, title=_('Add Group'))
Ejemplo n.º 2
0
def add_group():
    form = AddGroupForm()
    if form.validate_on_submit():
        form.save()
        flash(_("Group successfully added."), "success")
        return redirect(url_for("management.groups"))

    return render_template("management/group_form.html", form=form,
                           title=_("Add Group"))
Ejemplo n.º 3
0
def add_group():
    form = AddGroupForm()
    if form.validate_on_submit():
        form.save()
        flash(_("Group successfully added."), "success")
        return redirect(url_for("management.groups"))

    return render_template("management/group_form.html", form=form,
                           title=_("Add Group"))
Ejemplo n.º 4
0
    def post(self):
        form = AddGroupForm()
        if form.validate_on_submit():
            form.save()
            flash(_('Group added.'), 'success')
            return redirect(url_for('management.groups'))

        return render_template(
            'management/group_form.html', form=form, title=_('Add Group')
        )