From 58ee947b352fa7605ef8cc8560873b9abad541d4 Mon Sep 17 00:00:00 2001 From: Robin Ward Date: Fri, 14 Aug 2020 21:03:41 -0400 Subject: [PATCH] FIX: Mobile group add dropdown was broken It looks like we removed the bulk add modal but didn't update the mobile template. --- .../discourse/app/templates/mobile/group-index.hbs | 2 +- .../addon/components/group-members-dropdown.js | 13 +++---------- 2 files changed, 4 insertions(+), 11 deletions(-) diff --git a/app/assets/javascripts/discourse/app/templates/mobile/group-index.hbs b/app/assets/javascripts/discourse/app/templates/mobile/group-index.hbs index 21a02abe3a0..36ec17ebdfa 100644 --- a/app/assets/javascripts/discourse/app/templates/mobile/group-index.hbs +++ b/app/assets/javascripts/discourse/app/templates/mobile/group-index.hbs @@ -10,8 +10,8 @@ {{#if canManageGroup}} {{#if currentUser.admin}} {{group-members-dropdown + groupName=model.full_name showAddMembersModal=(route-action "showAddMembersModal") - showBulkAddModal=(route-action "showBulkAddModal") }} {{else}} {{d-button diff --git a/app/assets/javascripts/select-kit/addon/components/group-members-dropdown.js b/app/assets/javascripts/select-kit/addon/components/group-members-dropdown.js index 7e3c82a2e58..d9b363dbe3a 100644 --- a/app/assets/javascripts/select-kit/addon/components/group-members-dropdown.js +++ b/app/assets/javascripts/select-kit/addon/components/group-members-dropdown.js @@ -14,19 +14,12 @@ export default DropdownSelectBoxComponent.extend({ const items = [ { id: "showAddMembersModal", - name: I18n.t("groups.add_members.title"), + name: I18n.t("groups.add_members.title", { + group_name: this.groupName + }), icon: "user-plus" } ]; - - if (this.currentUser.admin) { - items.push({ - id: "showBulkAddModal", - name: I18n.t("admin.groups.bulk_add.title"), - icon: "users" - }); - } - return items; }),