{"action":"opened","issue":{"url":"https://api.github.com/repos/dragonrider23/dandelion/issues/6","labels_url":"https://api.github.com/repos/dragonrider23/dandelion/issues/6/labels{/name}","comments_url":"https://api.github.com/repos/dragonrider23/dandelion/issues/6/comments","events_url":"https://api.github.com/repos/dragonrider23/dandelion/issues/6/events","html_url":"https://github.com/dragonrider23/dandelion/issues/6","id":57386329,"number":6,"title":"Cheesto History","user":{"login":"dragonrider23","id":6619743,"avatar_url":"https://avatars.githubusercontent.com/u/6619743?v=3","gravatar_id":"","url":"https://api.github.com/users/dragonrider23","html_url":"https://github.com/dragonrider23","followers_url":"https://api.github.com/users/dragonrider23/followers","following_url":"https://api.github.com/users/dragonrider23/following{/other_user}","gists_url":"https://api.github.com/users/dragonrider23/gists{/gist_id}","starred_url":"https://api.github.com/users/dragonrider23/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dragonrider23/subscriptions","organizations_url":"https://api.github.com/users/dragonrider23/orgs","repos_url":"https://api.github.com/users/dragonrider23/repos","events_url":"https://api.github.com/users/dragonrider23/events{/privacy}","received_events_url":"https://api.github.com/users/dragonrider23/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/dragonrider23/dandelion/labels/enhancement","name":"enhancement","color":"84b6eb"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-02-11T22:17:50Z","updated_at":"2015-02-11T22:17:50Z","closed_at":null,"body":"Coworker's suggestion: It would be nice to have a history of Cheesto status changes.\r\n\r\nThe old software we used that was eventually replaced by the Cheesto system in Dandelion kept a history of status changes. This could be used to keep track of time sick, vacation, etc.\r\n\r\nIt will be considered but may be outside the scope of the Dandelion core. Perhaps when the plugin system is implemented, an official plugin could be created that would manage that.\r\n\r\nImplementation:\r\n\r\nDatabase: new table of cheesto_history. The fields would be id, uid (user ID), state (PHP serialized array of status, message, time, etc.), date (date the history record was created). \r\n\r\nConfiguration file: new setting of 'cheestoHistoryKeep' which will be the number of days to keep a history.\r\n\r\nCode: A garbage collector would be implemented to run that would clean up the history table from time to time to enforce the keep length. Any UI would only show the set number of days regardless of if there are older records in the history table.\r\n\r\nUI: new template page would be created that would show the history for the logged in user. History is not editable, or deletable. The only time it will disappear is if it's older than the set days to keep.\r\n\r\nAPI: new API endpoint to retrieve history in JSON format. The API would take a start index and a limit of records to return. "}}