{"action":"created","issue":{"url":"https://api.github.com/repos/thekordy/ticketit/issues/33","labels_url":"https://api.github.com/repos/thekordy/ticketit/issues/33/labels{/name}","comments_url":"https://api.github.com/repos/thekordy/ticketit/issues/33/comments","events_url":"https://api.github.com/repos/thekordy/ticketit/issues/33/events","html_url":"https://github.com/thekordy/ticketit/issues/33","id":109238439,"number":33,"title":"Manage Agents \"Removed Agent\" is still being auto assigned new tickets","user":{"login":"fishmad","id":12012101,"avatar_url":"https://avatars.githubusercontent.com/u/12012101?v=3","gravatar_id":"","url":"https://api.github.com/users/fishmad","html_url":"https://github.com/fishmad","followers_url":"https://api.github.com/users/fishmad/followers","following_url":"https://api.github.com/users/fishmad/following{/other_user}","gists_url":"https://api.github.com/users/fishmad/gists{/gist_id}","starred_url":"https://api.github.com/users/fishmad/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fishmad/subscriptions","organizations_url":"https://api.github.com/users/fishmad/orgs","repos_url":"https://api.github.com/users/fishmad/repos","events_url":"https://api.github.com/users/fishmad/events{/privacy}","received_events_url":"https://api.github.com/users/fishmad/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/thekordy/ticketit/labels/bug","name":"bug","color":"fc2929"}],"state":"open","locked":false,"assignee":{"login":"thekordy","id":11343048,"avatar_url":"https://avatars.githubusercontent.com/u/11343048?v=3","gravatar_id":"","url":"https://api.github.com/users/thekordy","html_url":"https://github.com/thekordy","followers_url":"https://api.github.com/users/thekordy/followers","following_url":"https://api.github.com/users/thekordy/following{/other_user}","gists_url":"https://api.github.com/users/thekordy/gists{/gist_id}","starred_url":"https://api.github.com/users/thekordy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/thekordy/subscriptions","organizations_url":"https://api.github.com/users/thekordy/orgs","repos_url":"https://api.github.com/users/thekordy/repos","events_url":"https://api.github.com/users/thekordy/events{/privacy}","received_events_url":"https://api.github.com/users/thekordy/received_events","type":"User","site_admin":false},"milestone":null,"comments":1,"created_at":"2015-10-01T06:31:44Z","updated_at":"2015-10-01T23:50:57Z","closed_at":null,"body":"I removed an agent from one of my categories as I had too many, but when I submitted a new ticket later on it still assigned the new ticket to that removed agent.\r\n\r\nI notice the relationship reference remains in pivot table `ticketit_categories_users` \r\nThis may still have a purpose - if I was to manually delete the mysql row (I cant anyway) it would cause problems with any 'existing comments' that agent previously made on old tickets.\r\n\r\nSuggest adding a flag in Pivot table to indicate if agent is still 'active' in that 'category'.\r\nso when auto assign of tickets a query would check to see only 'active agents'."},"comment":{"url":"https://api.github.com/repos/thekordy/ticketit/issues/comments/144879725","html_url":"https://github.com/thekordy/ticketit/issues/33#issuecomment-144879725","issue_url":"https://api.github.com/repos/thekordy/ticketit/issues/33","id":144879725,"user":{"login":"thekordy","id":11343048,"avatar_url":"https://avatars.githubusercontent.com/u/11343048?v=3","gravatar_id":"","url":"https://api.github.com/users/thekordy","html_url":"https://github.com/thekordy","followers_url":"https://api.github.com/users/thekordy/followers","following_url":"https://api.github.com/users/thekordy/following{/other_user}","gists_url":"https://api.github.com/users/thekordy/gists{/gist_id}","starred_url":"https://api.github.com/users/thekordy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/thekordy/subscriptions","organizations_url":"https://api.github.com/users/thekordy/orgs","repos_url":"https://api.github.com/users/thekordy/repos","events_url":"https://api.github.com/users/thekordy/events{/privacy}","received_events_url":"https://api.github.com/users/thekordy/received_events","type":"User","site_admin":false},"created_at":"2015-10-01T23:50:57Z","updated_at":"2015-10-01T23:50:57Z","body":"I hope this patch fixes the issue"}}