You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In my REST If I GET: "events":["Noël", "Pâques", "Foo"] When I PUT : "events":["Noël", "Pâques"] to my REST I have : "events":["Noël", "Pâques"]... PERFECT :)
when i PUT an "events":["Pâques", "Foo"] I get : "events":{"1":"P\u00e2ques","2":"Foo"} . It's due to the json ENcode comportment : array(0 => 'A', 1 => 'B') => ['A', 'B'] array(1 => 'B', 2 => 'C') => {1: "B", 2: "C"}. if there isn't the 0, it changes it to objects. How can I reorganise it before serialization
I would like to know if it's possible to create a serializer handler for an array collection which contains specified object who implements TagInterface.
I know I just have to use an array_values($collection->toArray()). Because when I remove an object from the collection. I delete the continuity of ids. I just don't know where to handle that...
Thanks
Thanks a lot
The text was updated successfully, but these errors were encountered:
In my REST If I GET: "events":["Noël", "Pâques", "Foo"] When I PUT : "events":["Noël", "Pâques"] to my REST I have : "events":["Noël", "Pâques"]... PERFECT :)
when i PUT an "events":["Pâques", "Foo"] I get : "events":{"1":"P\u00e2ques","2":"Foo"} . It's due to the json ENcode comportment : array(0 => 'A', 1 => 'B') => ['A', 'B'] array(1 => 'B', 2 => 'C') => {1: "B", 2: "C"}. if there isn't the 0, it changes it to objects. How can I reorganise it before serialization
I would like to know if it's possible to create a serializer handler for an array collection which contains specified object who implements TagInterface.
I know I just have to use an array_values($collection->toArray()). Because when I remove an object from the collection. I delete the continuity of ids. I just don't know where to handle that...
Thanks
Thanks a lot
The text was updated successfully, but these errors were encountered: