Unable to save associated BTM data #15407
Milestone
Comments
|
Is the |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
|
Is the |
This is a (multiple allowed):
bug
enhancement
feature-discussion (RFC)
CakePHP Version: 4.2.4
Platform and Target: PHP 7.4.12, MacOS 10.15.7
What you did
Trying to patch/save a belongs to many association data when a primary key is non-standard (in the sense that I have a composite pk) doesn't work.
What happened
Cannot insert row, some of the primary key values are missing. Got (155, 123, ), expecting (post_id, tag_id, primary)What you expected to happen
I should be able to patch the
$postand have it save the Tags association. This is working for me in my old Cake 3.3 project. I've tried debugging on my own but I don't know where the marshaller is going wrong or if the shape of my data is wrong.The text was updated successfully, but these errors were encountered: