I need an example of how to get a TreePanel to use its TreeStore Proxy to write new records to my database.

At the moment my tree view updates ok but there is no syncing to the rest proxy.

I am basically adding nodes to the tree like this:

where selectedRow is a number and newRecord is a new model of my store's model definition.

Hopefully someone can point me to example code otherwise it's back to dredging through the base code again I guess.