DatGuy has uploaded a new change for review. (
https://gerrit.wikimedia.org/r/334394 )
Change subject: Add confirmation box
......................................................................
Add confirmation box
Adding a confirmation box if a user accepts/rejects a translator.
Bug: T60706
Change-Id: I13f132ed08e6be55363417db5930769bd1bc16b3
---
M resources/js/ext.translate.special.managetranslatorsandbox.js
1 file changed, 21 insertions(+), 0 deletions(-)
git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Translate
refs/changes/94/334394/1
diff --git a/resources/js/ext.translate.special.managetranslatorsandbox.js
b/resources/js/ext.translate.special.managetranslatorsandbox.js
index d95e962..ab87d8c 100644
--- a/resources/js/ext.translate.special.managetranslatorsandbox.js
+++ b/resources/js/ext.translate.special.managetranslatorsandbox.js
@@ -122,6 +122,12 @@
.addClass( 'accept mw-ui-button
mw-ui-progressive' )
.text( mw.msg(
'tsb-accept-button-label' ) )
.on( 'click', function () {
+
+ if (
window.confirm("Are you sure?") == true {
+ continue;
+ } else {
+ break;
+
window.tsbUpdatingUsers
= true;
doApiAction( {
@@ -137,6 +143,11 @@
.addClass( 'reject mw-ui-button
mw-ui-destructive' )
.text( mw.msg(
'tsb-reject-button-label' ) )
.on( 'click', function () {
+ if (
window.confirm("Are you sure?") == true {
+ continue;
+ } else {
+ break;
+
window.tsbUpdatingUsers
= true;
doApiAction( {
@@ -280,6 +291,11 @@
.addClass( 'accept-all
mw-ui-button mw-ui-progressive' )
.text( mw.msg(
'tsb-accept-all-button-label' ) )
.on( 'click', function () {
+ if (
window.confirm("Are you sure?") == true {
+ continue;
+ } else {
+ break;
+
window.tsbUpdatingUsers
= true;
doApiAction( {
@@ -295,6 +311,11 @@
.addClass( 'reject-all
mw-ui-button mw-ui-destructive' )
.text( mw.msg(
'tsb-reject-all-button-label' ) )
.on( 'click', function () {
+ if (
window.confirm("Are you sure?") == true {
+ continue;
+ } else {
+ break;
+
window.tsbUpdatingUsers
= true;
doApiAction( {
--
To view, visit https://gerrit.wikimedia.org/r/334394
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I13f132ed08e6be55363417db5930769bd1bc16b3
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Translate
Gerrit-Branch: master
Gerrit-Owner: DatGuy <[email protected]>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits