Merge pull request #6761 from mrfinch/saurabh/show-popup
FIX:show popup before bulk invite
This commit is contained in:
parent
126be6c478
commit
f4d8a330c3
|
@ -25,5 +25,22 @@ export default Em.Component.extend(UploadMixin, {
|
||||||
|
|
||||||
uploadDone() {
|
uploadDone() {
|
||||||
bootbox.alert(I18n.t("user.invited.bulk_invite.success"));
|
bootbox.alert(I18n.t("user.invited.bulk_invite.success"));
|
||||||
}
|
},
|
||||||
|
|
||||||
|
uploadOptions() {
|
||||||
|
return { autoUpload: false };
|
||||||
|
},
|
||||||
|
|
||||||
|
_init: function() {
|
||||||
|
const $upload = this.$();
|
||||||
|
|
||||||
|
$upload.on("fileuploadadd", (e, data) => {
|
||||||
|
bootbox.confirm(
|
||||||
|
I18n.t("user.invited.bulk_invite.confirmation_message"),
|
||||||
|
I18n.t("cancel"),
|
||||||
|
I18n.t("go_ahead"),
|
||||||
|
result => (result ? data.submit() : data.abort())
|
||||||
|
);
|
||||||
|
});
|
||||||
|
}.on("didInsertElement")
|
||||||
});
|
});
|
||||||
|
|
|
@ -96,7 +96,9 @@ export default Em.Mixin.create({
|
||||||
});
|
});
|
||||||
|
|
||||||
$upload.on("fileuploadfail", (e, data) => {
|
$upload.on("fileuploadfail", (e, data) => {
|
||||||
|
if (!data || (data && data.errorThrown !== "abort")) {
|
||||||
displayErrorForUpload(data);
|
displayErrorForUpload(data);
|
||||||
|
}
|
||||||
reset();
|
reset();
|
||||||
});
|
});
|
||||||
}.on("didInsertElement"),
|
}.on("didInsertElement"),
|
||||||
|
|
|
@ -213,6 +213,7 @@ en:
|
||||||
submit: "Submit"
|
submit: "Submit"
|
||||||
generic_error: "Sorry, an error has occurred."
|
generic_error: "Sorry, an error has occurred."
|
||||||
generic_error_with_reason: "An error occurred: %{error}"
|
generic_error_with_reason: "An error occurred: %{error}"
|
||||||
|
go_ahead: "Go ahead"
|
||||||
sign_up: "Sign Up"
|
sign_up: "Sign Up"
|
||||||
log_in: "Log In"
|
log_in: "Log In"
|
||||||
age: "Age"
|
age: "Age"
|
||||||
|
@ -996,6 +997,7 @@ en:
|
||||||
text: "Bulk Invite from File"
|
text: "Bulk Invite from File"
|
||||||
success: "File uploaded successfully, you will be notified via message when the process is complete."
|
success: "File uploaded successfully, you will be notified via message when the process is complete."
|
||||||
error: "Sorry, file should be CSV format."
|
error: "Sorry, file should be CSV format."
|
||||||
|
confirmation_message: "You’re about to email invites to everyone in the uploaded file."
|
||||||
|
|
||||||
password:
|
password:
|
||||||
title: "Password"
|
title: "Password"
|
||||||
|
|
Loading…
Reference in New Issue