Changeset - cc70797e70e1
[Not reviewed]
stable
0 1 0
Mads Kiilerich - 3 years ago 2022-06-27 20:30:00
mads@kiilerich.com
usergroup: fix adding permission

Clicking "Add new" on /_admin/user_groups/1/edit/perms would flicker the input
fields, and then show "User group permissions updated".

That turns out to be because HTML button tags default to 'submit' inside forms,
and in this place (but not for user or repo group permissions) we didn't
specify the button type as 'button'.

There might be other similar problems.
1 file changed with 1 insertions and 1 deletions:
0 comments (0 inline, 0 general)
kallithea/templates/admin/user_groups/user_group_edit_perms.html
Show inline comments
 
@@ -77,7 +77,7 @@ ${h.form(url('edit_user_group_perms_upda
 
                <tr class="new_members last_new_member" id="add_perm_input"><td colspan="6"></td></tr>
 
                <tr>
 
                    <td colspan="6">
 
                        <button id="add_perm" class="btn btn-link btn-xs">
 
                        <button type="button" id="add_perm" class="btn btn-link btn-xs">
 
                            <i class="icon-plus"></i>${_('Add new')}
 
                        </button>
 
                    </td>
0 comments (0 inline, 0 general)