{"action":"created","issue":{"url":"https://api.github.com/repos/valor-software/ng2-tree/issues/155","repository_url":"https://api.github.com/repos/valor-software/ng2-tree","labels_url":"https://api.github.com/repos/valor-software/ng2-tree/issues/155/labels{/name}","comments_url":"https://api.github.com/repos/valor-software/ng2-tree/issues/155/comments","events_url":"https://api.github.com/repos/valor-software/ng2-tree/issues/155/events","html_url":"https://github.com/valor-software/ng2-tree/issues/155","id":268757560,"number":155,"title":"feature request: canDeselect promise for validation purposes ","user":{"login":"entrodus","id":7075596,"avatar_url":"https://avatars2.githubusercontent.com/u/7075596?v=4","gravatar_id":"","url":"https://api.github.com/users/entrodus","html_url":"https://github.com/entrodus","followers_url":"https://api.github.com/users/entrodus/followers","following_url":"https://api.github.com/users/entrodus/following{/other_user}","gists_url":"https://api.github.com/users/entrodus/gists{/gist_id}","starred_url":"https://api.github.com/users/entrodus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/entrodus/subscriptions","organizations_url":"https://api.github.com/users/entrodus/orgs","repos_url":"https://api.github.com/users/entrodus/repos","events_url":"https://api.github.com/users/entrodus/events{/privacy}","received_events_url":"https://api.github.com/users/entrodus/received_events","type":"User","site_admin":false},"labels":[{"id":299409977,"url":"https://api.github.com/repos/valor-software/ng2-tree/labels/enhancement","name":"enhancement","color":"84b6eb","default":true}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2017-10-26T13:22:08Z","updated_at":"2017-10-29T11:08:54Z","closed_at":null,"author_association":"NONE","body":"It would be very handy to have a method for controlling whether a currently selected node can be deselected through a promise/observable function which could be used for validation purposes. \r\n\r\nI am currently using ng2-tree component to visualise all of my entities on the left side and display all editable properties of the selected entity on the right side of my application. \r\n\r\nIt would be great if i could hook to a canDeselect promise before user navigates to a new node so i could apply validation checks and user prompts for saving currently selected node before navigating to a new one. "},"comment":{"url":"https://api.github.com/repos/valor-software/ng2-tree/issues/comments/340254060","html_url":"https://github.com/valor-software/ng2-tree/issues/155#issuecomment-340254060","issue_url":"https://api.github.com/repos/valor-software/ng2-tree/issues/155","id":340254060,"user":{"login":"entrodus","id":7075596,"avatar_url":"https://avatars2.githubusercontent.com/u/7075596?v=4","gravatar_id":"","url":"https://api.github.com/users/entrodus","html_url":"https://github.com/entrodus","followers_url":"https://api.github.com/users/entrodus/followers","following_url":"https://api.github.com/users/entrodus/following{/other_user}","gists_url":"https://api.github.com/users/entrodus/gists{/gist_id}","starred_url":"https://api.github.com/users/entrodus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/entrodus/subscriptions","organizations_url":"https://api.github.com/users/entrodus/orgs","repos_url":"https://api.github.com/users/entrodus/repos","events_url":"https://api.github.com/users/entrodus/events{/privacy}","received_events_url":"https://api.github.com/users/entrodus/received_events","type":"User","site_admin":false},"created_at":"2017-10-29T11:08:54Z","updated_at":"2017-10-29T11:08:54Z","author_association":"NONE","body":"@rychkog Yes. A guard that would also not allow the selection of a new node until the deselection promise of the previous node is resolved and satisfied."}}
{"actor":{"display_login":"entrodus"}}