Refresh treeview if a new device is added.
Updated the delete to check for full primary key attributes before deleting.