Resolve "User deletion modal with same info for delete user / delete user and contributions"
This commit is contained in:
parent
d08f2005d9
commit
54caf96164
4 changed files with 12 additions and 7 deletions
|
@ -52,16 +52,15 @@
|
|||
text() {
|
||||
const keepContributionsText = s__(`AdminArea|
|
||||
You are about to permanently delete the user %{username}.
|
||||
This will delete all of the issues, merge requests, and groups linked to them.
|
||||
Issues, merge requests, and groups linked to them will be transferred to a system-wide "Ghost-user".
|
||||
To avoid data loss, consider using the %{strong_start}block user%{strong_end} feature instead.
|
||||
Once you %{strong_start}Delete user%{strong_end}, it cannot be undone or recovered.`);
|
||||
|
||||
const deleteContributionsText = s__(`AdminArea|
|
||||
You are about to permanently delete the user %{username}.
|
||||
Issues, merge requests, and groups linked to them will be transferred to a system-wide "Ghost-user".
|
||||
This will delete all of the issues, merge requests, and groups linked to them.
|
||||
To avoid data loss, consider using the %{strong_start}block user%{strong_end} feature instead.
|
||||
Once you %{strong_start}Delete user%{strong_end}, it cannot be undone or recovered.`);
|
||||
|
||||
return sprintf(this.deleteContributions ? deleteContributionsText : keepContributionsText,
|
||||
{
|
||||
username: `<strong>${_.escape(this.username)}</strong>`,
|
||||
|
|
|
@ -43,7 +43,7 @@
|
|||
delete_user_url: admin_user_path(user),
|
||||
block_user_url: block_admin_user_path(user),
|
||||
username: user.name,
|
||||
delete_contributions: 'false' }, type: 'button' }
|
||||
delete_contributions: false }, type: 'button' }
|
||||
= s_('AdminUsers|Delete user')
|
||||
|
||||
%li
|
||||
|
@ -52,5 +52,5 @@
|
|||
delete_user_url: admin_user_path(user, hard_delete: true),
|
||||
block_user_url: block_admin_user_path(user),
|
||||
username: user.name,
|
||||
delete_contributions: 'true' }, type: 'button' }
|
||||
delete_contributions: true }, type: 'button' }
|
||||
= s_('AdminUsers|Delete user and contributions')
|
||||
|
|
|
@ -183,7 +183,7 @@
|
|||
delete_user_url: admin_user_path(@user),
|
||||
block_user_url: block_admin_user_path(@user),
|
||||
username: @user.name,
|
||||
delete_contributions: 'false' }, type: 'button' }
|
||||
delete_contributions: false }, type: 'button' }
|
||||
= s_('AdminUsers|Delete user')
|
||||
- else
|
||||
- if @user.solo_owned_groups.present?
|
||||
|
@ -215,7 +215,7 @@
|
|||
delete_user_url: admin_user_path(@user, hard_delete: true),
|
||||
block_user_url: block_admin_user_path(@user),
|
||||
username: @user.name,
|
||||
delete_contributions: 'true' }, type: 'button' }
|
||||
delete_contributions: true }, type: 'button' }
|
||||
= s_('AdminUsers|Delete user and contributions')
|
||||
- else
|
||||
%p
|
||||
|
|
|
@ -0,0 +1,6 @@
|
|||
---
|
||||
title: Correct text and functionality for delete user / delete user and contributions
|
||||
modal.
|
||||
merge_request: 18463
|
||||
author: Marc Schwede
|
||||
type: fixed
|
Loading…
Reference in a new issue