mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-06-29 05:26:13 +00:00
WIP adapt fixtures script for sf4
This commit is contained in:
parent
f61d54d4cf
commit
96dbd06b75
@ -23,6 +23,7 @@ use Doctrine\Common\DataFixtures\AbstractFixture;
|
||||
use Doctrine\Common\DataFixtures\OrderedFixtureInterface;
|
||||
use Chill\CustomFieldsBundle\Entity\CustomFieldLongChoice\Option;
|
||||
|
||||
error_reporting(0);
|
||||
/**
|
||||
* Load some Options
|
||||
*
|
||||
@ -131,6 +132,18 @@ class LoadOption extends AbstractFixture implements OrderedFixtureInterface
|
||||
|
||||
|
||||
foreach ($companiesParents as $text) {
|
||||
|
||||
// sf4 check: erreur non résolue ici avec $text: In PDOStatement.php line 81: Notice: Array to string conversion
|
||||
//
|
||||
// et avec error_reporting(0):
|
||||
|
||||
// An exception occurred while executing 'INSERT INTO custom_field_long_choice_options (id, key, text, internal_key, active, parent_id) VALUES (?, ?, ?, ?, ?, ?)' with params [1304, "company", {
|
||||
// "fr":"Grandes Entreprises","nl":"Grotes Bedrijven","en":"Big Companies"}, "", 1, null]:
|
||||
//
|
||||
// SQLSTATE[22P02]: Invalid text representation: 7 ERROR: invalid input syntax for type json
|
||||
// DETAIL: Token "Array" is invalid.
|
||||
// CONTEXT: JSON data, line 1: Array
|
||||
|
||||
$parent = (new Option())
|
||||
->setText($text)
|
||||
->setKey('company')
|
||||
|
Loading…
x
Reference in New Issue
Block a user