Describe your bug or feature request.

On the Commerce dashboard (/admin/commerce), the inbox needs Drupal's AJAX library:

Clicking a message calls Drupal.ajax() to mark it as read.

The Dismiss link uses the use-ajax class.

The commerce/dashboard library in commerce.libraries.yml does not declare core/drupal.ajax. It works only when another module, such as Toolbar, loads AJAX on the page. Without it, Drupal.ajax is undefined. The read click then throws a JavaScript error, and Dismiss does a full page load to the route.

Affects Commerce 3.x. 8.x-2.x has no inbox.

Issue fork commerce-3633522

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

tbkot created an issue. See original summary.

tbkot’s picture

Status: Active » Needs review

  • tbkot committed 3d04eef2 on 3.x
    Issue #3633522: Add the 'core/drupal.ajax' dependencie so messages are...
jsacksick’s picture

Status: Needs review » Fixed

Now that this issue is closed, review the contribution record.

As a contributor, attribute any organization that helped you, or if you volunteered your own time.

Maintainers, credit people who helped resolve this issue.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.