Sep 11, 2015, 1:42 PM
[CLOSED] How to set NodeID to newly added node via script
I have following code:
When I set NodeID via Razor, or code-behind it works. How to do it via script?
function saveSearch(btn, text) {
if (btn == 'ok')
App.direct.SaveSearch(text, {
success: function (result) {
var store = App.TreePanel1.getStore();
node = store.getNodeById("savedSearches");
var childNode = node.appendChild({
internalId: "id_" + result,
text: result,
leaf: true,
})
alert(childNode.internalId)
}
});
};
Internal ID (NodeID) alerted is different from what I have assigned to childNode.When I set NodeID via Razor, or code-behind it works. How to do it via script?
Last edited by Daniil; Sep 15, 2015 at 7:12 AM.
Reason: [CLOSED]