Hi
When I try to add a category on a multi-domain site, I get this notice and this error:

Notice : Undefined index: domain_id dans domain_settings_form_submit() (ligne 123 dans /var/www/clients/client1/web32/web/sites/all/modules/contrib/domain/domain_settings/domain_settings.module).

PDOException : SQLSTATE[23000]: Integrity constraint violation: 1048 Column 'domain_id' cannot be null: INSERT INTO {domain_conf} (domain_id, settings) VALUES (:db_insert_placeholder_0, :db_insert_placeholder_1); Array ( [:db_insert_placeholder_0] => [:db_insert_placeholder_1] => a:1:{s:31:"eu_cookie_compliance_categories";a:1:{s:9:"essentiel";a:5:{s:6:"weight";i:0;s:12:"machine_name";s:9:"essentiel";s:5:"label";s:9:"Essentiel";s:11:"description";s:45:"Nécessaire au fonctionnement courant du site";s:22:"checkbox_default_state";s:7:"checked";}}} ) dans domain_conf_data_set() (ligne 133 dans /var/www/clients/client1/web32/web/sites/all/modules/contrib/domain/domain_conf/domain_conf.module).

Steps to reproduce

1. Install Domain Settings (and related modules)
2. Go to EU Cookie Compliance Categories page
3. Click "Add new category"
4. Fill form
5. Submit

Result

No category was created

Expected

Category to be generated for the domain that I'm using.

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

Stan-conseil created an issue. See original summary.

svenryen’s picture

Hi JC! Did you add one category successfully and did you then have issues adding a second one?

svenryen’s picture

Assigned: Unassigned » grayle
Issue summary: View changes

@Grayle

I was able to suppress the error message with the code in the issue branch, but I can't really save any categories when Domain Settings are enabled. Did we not test the with the Domain modules enabled?

[added steps to reproduce]

svenryen’s picture

Title: PDOException : SQLSTATE[23000] » Categories feature doesn't work with Domain Access
Issue tags: -multi domain

svenryen’s picture

Status: Active » Needs work
svenryen’s picture

Status: Needs work » Needs review

Seems like it's working once you disable the Translate Configuration module. There's a conflict between domain and languages which is not related to the bug in this issue.

svenryen’s picture

Assigned: grayle » Unassigned

Neslee Canil Pinto made their first commit to this issue’s fork.

neslee canil pinto’s picture

Version: 7.x-1.36 » 7.x-1.x-dev
Status: Needs review » Fixed

Status: Fixed » Closed (fixed)

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