Problem/Motivation

The Brandfolder Browser is not displaying when I edit my Brandfolder Media reference field.

Steps to reproduce

I followed the instructions in the Readme file:

  • I Configured the Brandfolder module with my API Key and I see sample images from my Brandfolder in the settings form. So, the connection to my Brandfolder is working.
  • I created a new Media Type with "Brandfolder Image" as the source.
  • I created a new entity reference field for the new Media Type

When I edit content containing the new media field, there is a link to "Create new media" or "Use Existing Media". Either way, I ultimately end up at /media/add/brandfolder_image where I only see 2 fields: "Name" and "Brandfolder Attachment ID". I was expecting to see the Brandfolder Browser at this point but it is not displayed.

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

rwsimmo created an issue. See original summary.

ndewhurst’s picture

Hi rwsimmo - thanks for filing the issue. Sorry about the confusion. The Brandfolder browser will only appear when you configure a media entity reference field to use a core Media Library widget (in the "Manage Form Display" settings form for the entity/bundle where you're using the field). The README apparently needs to be fixed.
I've also more recently added support for the Entity Browser module as an alternative to Media Library.
We're also stabilizing and reconciling a number of different module versions. What Drupal and PHP versions are you currently using (and/or planning to use)?

  • ndewhurst committed 35326dff on 2.0.x
    Issue #3405306 update README to clarify Media Library widget, etc.
    
rwsimmo’s picture

Thanks for the reply Nathanael! I made the form display change you suggested. Now the node edit form displays an "Add Media" button and when the button is pressed, an "Add or select" dialog is displayed. The dialog displays some labels from Brandfolder but it says "No Brandfolder assets found."

I have detailed logging turned on and I am seeing 3 API calls made to Brandfolder for labels, collections, and assets. All 3 API calls are returning a status of 200.

In addition, I have tested the API calls in Postman the best I can and all 3 calls are returning data. However, I am not using the complex search parameter because I have not yet figured out how to enter that in Postman. For example:

"search":"(collection_key:(\"redacted\")) AND (section_key:(\"redacted\")) AND (filetype:(\"jpg\" OR \"png\" OR \"gif\" OR \"tiff\" OR \"svg\" OR \"webp\"))"

rwsimmo’s picture

I forgot to add that I am testing the module using Drupal 9.5.10 and PHP 8.1. However, we are using Drupal 10 and PHP 8.1 on all of our production sites.

rwsimmo’s picture

I am now getting images in the Brandfolder Media Browser. I had to adjust the Brandfolder collection and section in my Brandfolder Image Media Type to something with image types supported on the Drupal site.

ndewhurst’s picture

Great to hear!
For our info, are there other image types not currently supported that you would hope to use as part of the integration?
Also, you can test on Drupal 10 now using the 5.0.x-dev branch/release. I'd be curious to get your feedback there.

ndewhurst’s picture

Status: Active » Fixed

Status: Fixed » Closed (fixed)

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