def text(params = {})
      k = key.split('.')
      k.unshift('notification') if k.first != 'notification'
      if params.has_key?(:target)
        k.insert(1, params[:target])
      else
        k.insert(1, target.to_resource_name)
      end
      k.push('text')
      k = k.join('.')

      attrs = (parameters.symbolize_keys.merge(params) || {}).merge(
        group_member_count:          group_member_count,
        group_notification_count:    group_notification_count,
        group_member_notifier_count: group_member_notifier_count,
        group_notifier_count:        group_notifier_count
      )

      # Generate the :default fallback key without using pluralization key :count
      default = I18n.t(k, attrs)
      I18n.t(k, attrs.merge(count: group_notification_count, default: default))
    end
def text(params = {})
      k = key.split('.')
      k.unshift('notification') if k.first != 'notification'
      if params.has_key?(:target)
        k.insert(1, params[:target])
      else
        k.insert(1, target.to_resource_name)
      end
      k.push('text')
      k = k.join('.')

      attrs = (parameters.symbolize_keys.merge(params) || {}).merge(
        group_member_count:          group_member_count,
        group_notification_count:    group_notification_count,
        group_member_notifier_count: group_member_notifier_count,
        group_notifier_count:        group_notifier_count
      )

      # Generate the :default fallback key without using pluralization key :count
      default = I18n.t(k, attrs)
      I18n.t(k, attrs.merge(count: group_notification_count, default: default))
    end
Virtual attribute returning text description of the notification
 using the notification's key to translate using i18n.

 @param [Hash] params Parameters for rendering notification text
 @option params [String] :target Target type name to use as i18n text key
 @option params [Hash] others Parameters to be referred in i18n text
 @return [String] Rendered text