Copy data from a sibling in custom panel field

Hi there,

I have a quite complex structure field for wich children I made a custom field for the panel.

It works well !

And now what i would like to accomplish is a button : ‘copy data from previous item’. Wich would mean access data (almost all but one) from previous sibling in the structure, and copy them into my current field…

Is there any way to access structure data[n-1] ?

Thanks a lot !

Hi there,

i found a way with Vuex $store, accessing page content.

const id = this.$store.getters["content/id"]()
const models = this.$store.state.content.models
return models[id]

Thanks !