Uploaded image for project: 'Sakai'
  1. Sakai
  2. SAK-24727

Error on use of ResourceLoader.getFormattedMessage at MembershipManagerImpl

    XMLWordPrintable

Details

    • Resolved
    • MSGCNTR-574

    Description

      On MembershipManagerImpl you can find the following lines:
      member.setName(currentGroup.getTitle() + " " + rl.getFormattedMessage("participants_group_desc",new Object[]

      {currentGroup.getTitle()}));
      .......
      member.setName(roleId + " " + rl.getFormattedMessage("participants_role_desc",new Object[]{roleId}));

      The effect is that when user is composing a new message, in the select "To" users, will appear:
      <group_title1> 1 Group
      <group_title2> 2 Group
      ...
      <group_titleN> N Group
      <role_1> 1 Role
      <role_2> 2 Role
      ...
      <role_N> N Role
      Additionaly, the following key are bad configured in all properties bundle:
      participants_role_desc = Role
      participants_group_desc = Group

      They should be
      participants_role_desc = Role {0}
      participants_group_desc = Group {0}

      In other to make a proper (and logical) user of ResourceLoader.getFormattedMessage.

      Finally, MembershipManagerImpl code should be:

      member.setName(rl.getFormattedMessage("participants_group_desc",new Object[]{currentGroup.getTitle()}

      ));
      .......
      member.setName(rl.getFormattedMessage("participants_role_desc",new Object[]

      {roleId}

      ));

      I'll try to attach a patch as soon as possible.

      Gliffy Diagrams

        Zeplin

          Attachments

            Activity

              People

                baholladay Bryan Holladay
                arwhyte Anthony Whyte
                Votes:
                0 Vote for this issue
                Watchers:
                0 Start watching this issue

                Dates

                  Created:
                  Updated:
                  Resolved:

                  Git Integration