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'))
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"))
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') )