All add-ons currently require PHP 7.4 or greater.

On July 4th 2024 PHP 8.2 will be the new minimum requirement for all add-ons. Expect any add-on released after that date to require 8.2 or greater. Some releases may not immediately take advantage of 8.x specific features in PHP, which means you might, be able to continue using new releases in PHP 7.4, however, if you experience an error the first thing you should do is update to PHP 8.2 then create a support ticket if the error persists.

Publisher does not support the Fluid field type. Please do not contact asking when support will be available.

If you purchased an add-on from expressionengine.com, be sure to visit boldminded.com/claim to add the license to your account here on boldminded.com.

Ticket: Advanced Categories no_results displayed in publish page

Status Resolved
Add-on / Version Advanced Categories 1.1.1
Severity
EE Version 7.3.5

tectrain

Sep 15, 2023

Hello,

I installed the advanced categories, activated the expressionengine.com license on your page after creating the account and was able to activate the plugin.

then i added a new filed of type advanced categories to the fieldgroup of my channel (also tried without fieldgroup by directly assigning) with the option to hide built-in categories. I also ensured that a category group has been selected for that channel.


but when i edit a channel entry the field only says “no_results” and the categories tab is still there.

i even tried checking and unchecking categories in the field settings, didn’t change anything.

#1

tectrain

i just noticed that $this->settings is empty in function display_field…but the base64 encoded settings are there in the field_settings field in the exp_channel_fields table

#2

tectrain

it’s the fault of: $data = $this->prepareDataForDisplay($data);

#3

tectrain

very strange….

/**
     * @return array
     */
    private function getEntryCategories(): array
    {
        $entryId = $this->content_id();

        if (!$entryId) {
            return [];
        }

        if ($cache = $this->cache->get('entryCategories')) {
            return $cache;
        }

print_r($this->settings); // looks good
        $entry = ee('Model')->get('ChannelEntry', $entryId)->first();
print_r($this->settings); // empty

        // Cast them to a string just so it's consistent with what is return from the saved JSON object in the custom field.
        $cats = array_map(function ($value) {
            return (string) $value;
        }, $entry->Categories->pluck('cat_id'));
#4

BoldMinded (Brian)

Comment has been marked private.

#5

tectrain

amazing thank you.

now the issue arises which i was afraid of reading the docs: do i need to assign categories to the field? i would like to be able to choose any category from the assigned category group with the help of the advanced categories field type.

#6

BoldMinded (Brian)

Yes, if you want to be able to assign categories from multiple groups, then you need to assign each group to the channel and select which categories to display in the AC field.

Login to reply