Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Steve Smith 75 posts 158 karma points
    Sep 20, 2018 @ 10:16
    Steve Smith
    0

    "Relate to original" behaviour when copying content nodes

    Hello,

    After a bit of quick advice on the impact of ticking "Relate to original" when copying a content node in the back office.

    We had a report from a content editor this morning that some of the content changes they had been making to certain pages seem have been lost - and I'm investigating this problem now.

    One thing I noticed is that this particular content editor uses a process where by when they need a new page that's similar to an existing page, they simply make a copy of the existing page in the back office, and then edit the copy to suit their needs.

    e.g. if they make a page called "Product 1" and they need a "Product 2" page with similar content, they just make a copy of "Product 1" and then edit the copy to generate their "Product 2" page.

    I noticed that these are all being copied with "Relate to original" ticked - since that's the default. We don't actually need any form of relationship between the two pages, but then again they wouldn't have known what it even means (since its the default, they just left it as they found it).

    Because we've never used it before, I'm not sure what the actual purpose of "Relate to original" is - so I did a bit of Googling.

    Some of the results sent a shiver down my spine, because they suggest that if you have that box ticked, the correct behaviour is that when you make a content change to one of the nodes in the relationship, the other side is updated automatically to match.

    Is that really the case? Or is it - as other Google results suggest - literally just about creating a relationship in the database between the two nodes, so you can interrogate the relationship via an API (but with absolutely nothing changing when you save/publish)?

    Just trying to establish whether the fact they ticked "Relate to original" when copying the nodes could have caused content to change without their knowledge elsewhere - or whether I'm chasing a red herring.

    Thank you!

    Steve.

  • Kevin Jump 2343 posts 14890 karma points MVP 8x c-trib
    Sep 20, 2018 @ 15:20
    Kevin Jump
    2

    Hi Steve,

    I think some of those search results are a bit misleading - it's just creating the link and nothing changes when you save/publish.

    Relate to Orginial - allows for other things to be able to update content between nodes but but out of the box Umbraco doesn't do any updating when nodes are related.

    When you copy a node with "Relate to Original" on - Umbraco Creates a link between the two nodes via the RelationshipService in its umbracoRelation table.

    You can see these relationships in > developer / relation types / Relate on Copy (you can't delete them from the back office, but you can in code via the RelationService)

    The intention of the relation service is just to provide a pointer to other code that one node is somehow related to another, so examples of how this might be used are in Multilingual sites where the node in one language is related to the same one in another (so people can work out where translations go) - another example is a package (Nexu) that uses relationships to keep track of where a media item is used in content.

    but on a clean umbraco install there is nothing happening to update content between relationships.

  • Steve Smith 75 posts 158 karma points
    Sep 20, 2018 @ 16:10
    Steve Smith
    0

    OK many thanks for clarifying.

    So I was chasing a bit of a red herring with regards to that being the reason for content being overwritten/lost.

    I did think that would be crazy default behaviour :-)

Please Sign in or register to post replies

Write your reply to:

Draft