hi,
i try to customize Add item (content server activity) ,how can i use Node.Picker from the SDK?
there is documentation step by step how to do it?
where i add my code?
thank you
Hi @G_E-lior , I see that your question has not garnered any responses as yet. Have you had a chance to review the SDK documentation?
https://knowledge.opentext.com/go/67953154
The "Add Item" scenario needs both server and client parts cooperating. The server supplies the list of addable node types by the .../nodes/:id/addablenodetypes resource and the client loads the extensions to display the UI for adding them.
I am not aware of any code examples for the server side. I will need to implement a CSNode for your custom subtype. You can have a look at implementations for the built-in types like Folder or Document in Oclipse to get a clue about their addability.
There is no step-by-step walkthrough for this scenario in the Smart Ui SDK. You can have a look at commands/add.hello in the Smart UI SDK to see how to add an item to the "Add Item" menu. It is very minimum and does not contain any permission check, but it means just this:
enabled: function (status) { var data = status.data || {}; var addableTypes = data.addableTypes; return addableTypes && !!addableTypes.get(12345); // your subtype }
You can learn how to use the node picker from lib/src/csui/dialogs/node.picker/node.picker.md.