{"action":"created","issue":{"url":"https://api.github.com/repos/joomla-projects/custom-fields/issues/90","repository_url":"https://api.github.com/repos/joomla-projects/custom-fields","labels_url":"https://api.github.com/repos/joomla-projects/custom-fields/issues/90/labels{/name}","comments_url":"https://api.github.com/repos/joomla-projects/custom-fields/issues/90/comments","events_url":"https://api.github.com/repos/joomla-projects/custom-fields/issues/90/events","html_url":"https://github.com/joomla-projects/custom-fields/pull/90","id":156963800,"number":90,"title":"Add 'onFieldBeforeRender' and 'onFieldAfterRender' events to the field renderer for Custom Fields","user":{"login":"williamsandy","id":19549379,"avatar_url":"https://avatars.githubusercontent.com/u/19549379?v=3","gravatar_id":"","url":"https://api.github.com/users/williamsandy","html_url":"https://github.com/williamsandy","followers_url":"https://api.github.com/users/williamsandy/followers","following_url":"https://api.github.com/users/williamsandy/following{/other_user}","gists_url":"https://api.github.com/users/williamsandy/gists{/gist_id}","starred_url":"https://api.github.com/users/williamsandy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/williamsandy/subscriptions","organizations_url":"https://api.github.com/users/williamsandy/orgs","repos_url":"https://api.github.com/users/williamsandy/repos","events_url":"https://api.github.com/users/williamsandy/events{/privacy}","received_events_url":"https://api.github.com/users/williamsandy/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":7,"created_at":"2016-05-26T11:35:57Z","updated_at":"2016-05-27T15:11:07Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/joomla-projects/custom-fields/pulls/90","html_url":"https://github.com/joomla-projects/custom-fields/pull/90","diff_url":"https://github.com/joomla-projects/custom-fields/pull/90.diff","patch_url":"https://github.com/joomla-projects/custom-fields/pull/90.patch"},"body":"Added Events 'onFieldBeforeRender' and 'onFieldAfterRender' to\r\nFieldsHelper render method to give extensions that are not necessary\r\ncomponents or templates the ability to modify the output of the rendered\r\ncustom fields.\r\n\r\nWhy would we want to do this?\r\nWell, there are a few reasons why we want to do this, and one real life\r\nexample would be to do with inline editing. The two events would make it\r\neasier to make the rendered field editable in the front end when the\r\nuser logs in and wants to edit their article or item.\r\n\r\nWhy do we need two events?\r\n\r\nWell, the onFieldBeforeRender will allow modification directly to the\r\nvalue of the custom field before it is rendered with the layout. And in\r\nsome cases, this will be needed.\r\n\r\nThe onFieldAfterRender event is there for the case when we can wait\r\nuntil the custom field is fully rendered before doing any modification.\r\n\r\nBoth events take the context string and the display data so the plugin\r\ncan know what component is rendering the extra field, and from the data\r\nobject know the field type.\r\nWe also supply the layout file name reference so we can quickly know\r\nwhat type of rendering is occurring. This will be set to 'mustache' when\r\nwe are using mustache syntax tags\r\n\r\nNote: No manipulation of the display object is allowed in the\r\nonFieldAfterRender event as we are only using it as a reference at this\r\nstage."},"comment":{"url":"https://api.github.com/repos/joomla-projects/custom-fields/issues/comments/222172439","html_url":"https://github.com/joomla-projects/custom-fields/pull/90#issuecomment-222172439","issue_url":"https://api.github.com/repos/joomla-projects/custom-fields/issues/90","id":222172439,"user":{"login":"williamsandy","id":19549379,"avatar_url":"https://avatars.githubusercontent.com/u/19549379?v=3","gravatar_id":"","url":"https://api.github.com/users/williamsandy","html_url":"https://github.com/williamsandy","followers_url":"https://api.github.com/users/williamsandy/followers","following_url":"https://api.github.com/users/williamsandy/following{/other_user}","gists_url":"https://api.github.com/users/williamsandy/gists{/gist_id}","starred_url":"https://api.github.com/users/williamsandy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/williamsandy/subscriptions","organizations_url":"https://api.github.com/users/williamsandy/orgs","repos_url":"https://api.github.com/users/williamsandy/repos","events_url":"https://api.github.com/users/williamsandy/events{/privacy}","received_events_url":"https://api.github.com/users/williamsandy/received_events","type":"User","site_admin":false},"created_at":"2016-05-27T15:11:07Z","updated_at":"2016-05-27T15:11:07Z","body":"I have tested and updated the code."}}
{"actor":{"display_login":"williamsandy"}}