Merge pull request #10476 from opf/fix/41716/assignee-string

[41716] Consolidate assignee string in IAN center and team planner
pull/10487/head
Henriette Darge 3 years ago committed by GitHub
commit 643286d64a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      config/locales/js-en.yml
  2. 2
      frontend/src/app/features/in-app-notifications/center/menu/menu.component.ts
  3. 21
      frontend/src/app/features/team-planner/team-planner/planner/team-planner.component.ts
  4. 1
      modules/team_planner/config/locales/js-en.yml
  5. 10
      spec/features/notifications/notification_center/notification_center_sidemenu_spec.rb

@ -345,6 +345,7 @@ en:
</ul>
label_activate: "Activate"
label_assignee: 'Assignee'
label_add_column_after: "Add column after"
label_add_column_before: "Add column before"
label_add_columns: "Add columns"
@ -599,7 +600,6 @@ en:
link_text: 'Click here to load them'
menu:
accountable: 'Accountable'
assigned: 'Assigned'
by_project: 'Unread by project'
by_reason: 'Involvement'
inbox: 'Inbox'

@ -76,7 +76,7 @@ export class IanMenuComponent implements OnInit {
},
{
key: 'assigned',
title: this.I18n.t('js.notifications.menu.assigned'),
title: this.I18n.t('js.label_assignee'),
icon: 'assigned',
...getUiLinkForFilters({ filter: 'reason', name: 'assigned' }),
},

@ -77,7 +77,10 @@ import {
teamPlannerEventRemoved,
} from 'core-app/features/team-planner/team-planner/planner/team-planner.actions';
import { imagePath } from 'core-app/shared/helpers/images/path-helper';
import { skeletonEvents, skeletonResources } from './loading-skeleton-data';
import {
skeletonEvents,
skeletonResources,
} from './loading-skeleton-data';
import { CapabilitiesResourceService } from 'core-app/core/state/capabilities/capabilities.service';
import { ICapability } from 'core-app/core/state/capabilities/capability.model';
import { ToastService } from 'core-app/shared/components/toaster/toast.service';
@ -230,7 +233,7 @@ export class TeamPlannerComponent extends UntilDestroyedMixin implements OnInit,
text = {
add_existing: this.I18n.t('js.team_planner.add_existing'),
assignees: this.I18n.t('js.team_planner.label_assignee_plural'),
assignee: this.I18n.t('js.label_assignee'),
add_assignee: this.I18n.t('js.team_planner.add_assignee'),
remove_assignee: this.I18n.t('js.team_planner.remove_assignee'),
noData: this.I18n.t('js.team_planner.no_data'),
@ -383,7 +386,12 @@ export class TeamPlannerComponent extends UntilDestroyedMixin implements OnInit,
{ weekday: 'long', day: '2-digit' },
],
resourceAreaColumns: [
{ field: 'title', headerContent: this.text.assignees },
{
field: 'title',
headerContent: {
html: `<span class="spot-icon spot-icon_user-plus"></span> <span>${this.text.assignee}</span>`,
},
},
],
},
resourceTimelineTwoWeeks: {
@ -396,7 +404,12 @@ export class TeamPlannerComponent extends UntilDestroyedMixin implements OnInit,
{ weekday: 'short', day: '2-digit' },
],
resourceAreaColumns: [
{ field: 'title', headerContent: this.text.assignees },
{
field: 'title',
headerContent: {
html: `<span class="spot-icon spot-icon_user-plus"></span> <span>${this.text.assignee}</span>`,
},
},
],
},
},

@ -6,7 +6,6 @@ en:
create_new: 'New team planner'
title: 'Team planner'
unsaved_title: 'Unnamed team planner'
label_assignee_plural: 'Assignees'
no_data: 'Add assignees to set up your team planner.'
add_assignee: 'Add assignee'
remove_assignee: 'Remove assignee'

@ -73,7 +73,7 @@ describe "Notification center sidemenu", type: :feature, js: true do
center.expect_no_toaster
side_menu.expect_item_with_no_count 'Inbox'
side_menu.expect_item_with_no_count 'Assigned'
side_menu.expect_item_with_no_count 'Assignee'
side_menu.expect_item_with_no_count '@mentioned'
side_menu.expect_item_with_no_count 'Accountable'
side_menu.expect_item_with_no_count 'Watching'
@ -85,7 +85,7 @@ describe "Notification center sidemenu", type: :feature, js: true do
# Expect standard filters
side_menu.expect_item_with_count 'Inbox', 4
side_menu.expect_item_with_count 'Assigned', 1
side_menu.expect_item_with_count 'Assignee', 1
side_menu.expect_item_with_count '@mentioned', 1
side_menu.expect_item_with_count 'Accountable', 1
side_menu.expect_item_with_count 'Watching', 1
@ -100,7 +100,7 @@ describe "Notification center sidemenu", type: :feature, js: true do
# ... will change the filter counts
side_menu.expect_item_with_count 'Inbox', 3
side_menu.expect_item_with_count 'Assigned', 1
side_menu.expect_item_with_count 'Assignee', 1
side_menu.expect_item_with_count '@mentioned', 1
side_menu.expect_item_with_count 'Accountable', 1
side_menu.expect_item_with_no_count 'Watching'
@ -120,7 +120,7 @@ describe "Notification center sidemenu", type: :feature, js: true do
side_menu.finished_loading
center.mark_all_read
side_menu.expect_item_with_no_count 'Inbox'
side_menu.expect_item_with_no_count 'Assigned'
side_menu.expect_item_with_no_count 'Assignee'
side_menu.expect_item_with_no_count '@mentioned'
side_menu.expect_item_with_no_count 'Accountable'
side_menu.expect_item_with_no_count 'Watching'
@ -141,7 +141,7 @@ describe "Notification center sidemenu", type: :feature, js: true do
center.expect_no_item notification2, notification3, notification4
# Filter for "Assignee"
side_menu.click_item 'Assigned'
side_menu.click_item 'Assignee'
side_menu.finished_loading
center.expect_work_package_item notification2
center.expect_no_item notification, notification3, notification4

Loading…
Cancel
Save