-
-
Notifications
You must be signed in to change notification settings - Fork 9
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Can't Copy or Clone Craft Component That Uses Donkeytail Plugin #28
Comments
Just testing this out myself, and it seems to be working correctly for me. Are you cloning/copying before saving the entry, or after? They both seem to work for me, but just wanted to check. Quick video here - https://share.cleanshot.com/KDmtxGVT Are there are JS errors in your web developer console? Also worth checking #26 |
Hey there! Thanks for responding! To answer your question, cloning/copying don't work for me either before or after saving the entry. These screenshots might give you more info though! Thanks for asking about console errors! [ BEFORE Saving the Entry ] [ AFTER Saving the Entry ] |
Are you able to have a look at the Network tab, and look at the request, and then look at the Preview tab for the 500 error? The JS error showing |
Hey Josh! Just checking in. Any other information I can provide? |
Still not able to reproduce this one, sorry! In your last screenshot, can you scroll down to the "Payload" section so I can see what data is being sent to the server? |
Donkeytail maintainer here. We have a The result of However, when inspecting the local storage data, it looks like this:
We tried adding a hidden field input like Unfortunately we can't change the way this data is structured on our end at the moment. Do you have any thoughts on a way we could modify our form inputs so that when Smith serializes the data it doesn't expand the |
I think for representing the field as an object, relying on references to other objects as much as possible would be my go-to. We've got an outrageously large database and some matrix fields with 35 different component types in it, so those tables are really wide. I would imagine, however, that the DonkeyTail field could be serialized as
And since these are all pointers to other objects, it should be small. When I capture a similar object we've created that creates a carousel of "Announcements" to show on the site, where each announcement is another entry, I get this, which is all references:
And this one has an image
|
Yep, so that data structure is what I'm seeing, and understand the restrictions on your end regarding that. I'm pretty sure this is just down to how JavaScript handles object/arrays in this instance. I'll see what I can do on my end about this... |
What are you trying to do?
[ Unsure if this is a bug or a new feature. ]
I've opened a ticket with the Donkeytail plugin team, but I actually think this may belong in your repo! Not sure if you'd need to work together.
Essentially I'm trying to be able to copy and clone a Matrix Block that uses a Donkeytail field. The block is able to be copied UNTIL I use a pin. Then when I click 'copy' or 'clone' thereafter, nothing happens.
What's your proposed solution?
Not sure. This may need some work between both plugin teams.
Additional context
Currently using:
"craftcms/cms": "3.8.1"
"simplygoodwork/craft-donkeytail": "2.0.7"
"verbb/smith": "1.2.3"
Let me know if you need more info.
The text was updated successfully, but these errors were encountered: