compose: Hide subscribe button and change text for waiting period users.

Fixes #10124.
Users in the waiting period category cannot subscribe other users to
a stream. When a user tries to mention another unsubscribed user, a
warning message appears with a subscribe button on it to subscribe
the other user.
This commit removes the subscribe button and changes the warning text
for users in the waiting period category.
This commit is contained in:
Shubham Padia
2018-08-13 04:16:29 +05:30
committed by Tim Abbott
parent 3f019cafb2
commit e21e8c1bae
6 changed files with 18 additions and 1 deletions

View File

@@ -725,7 +725,11 @@ exports.initialize = function () {
});
if (existing_invites.indexOf(email) === -1) {
var context = {email: email, name: data.mentioned.full_name};
var context = {
email: email,
name: data.mentioned.full_name,
can_subscribe_other_users: page_params.can_subscribe_other_users,
};
var new_row = templates.render("compose-invite-users", context);
error_area.append(new_row);
}