on 2023 Jan 19 8:26 PM
Hi there!
I'm working on an impex who will update a CMSNavigationNode, and I need to clear the current list of children, before put another children's list.
I'm new about creation of impex files and her sintax, how can I make it?
Here i's my current impex:
INSERT_UPDATE CMSNavigationNode;uid[unique=true];$contentCV[unique=true];name;title;parent(uid, $contentCV);children(uid,$contentCV)[mode=append];links(uid, $contentCV);&nodeRef;parentPOS;
;PersonalDetailsNavNode;;Personal Details;Minha Conta;MyAccountNavNode;;;PersonalDetailsNavNode;1
;AddressBookNavNode;;Address Book;Meus Endereços;MyAccountNavNode;;;AddressBookNavNode;2
;OrderHistoryNavNode;;Order History;Meus Pedidos;MyAccountNavNode;;;OrderHistoryNavNode;3
;SignOutNavNode;;Sign Out;Sair;MyAccountNavNode;;;SignOutNavNode;4
Thanks for your time!
Request clarification before answering.
You don't need to clear the content of children first, just remove [mode=append] from your impex file when you want to replace existing children.
[mode=append] will append to current children, without append mode, impex will replace current children
INSERT_UPDATE CMSNavigationNode;uid[unique=true];$contentCV[unique=true];name;title;parent(uid, $contentCV);children(uid,$contentCV);links(uid, $contentCV);&nodeRef;parentPOS;
;PersonalDetailsNavNode;;Personal Details;Minha Conta;MyAccountNavNode;newChildren1,newChildren2;;PersonalDetailsNavNode;1
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You can use UPDATE instead of INSERT_UPDATE which will update with the latest list that you provide.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
| User | Count |
|---|---|
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.