{"action":"created","issue":{"url":"https://api.github.com/repos/torchbox/wagtail/issues/368","labels_url":"https://api.github.com/repos/torchbox/wagtail/issues/368/labels{/name}","comments_url":"https://api.github.com/repos/torchbox/wagtail/issues/368/comments","events_url":"https://api.github.com/repos/torchbox/wagtail/issues/368/events","html_url":"https://github.com/torchbox/wagtail/issues/368","id":36452796,"number":368,"title":"Add functionality for 'singleton snippets' (aka Settings)","user":{"login":"timheap","id":132147,"avatar_url":"https://avatars.githubusercontent.com/u/132147?v=3","gravatar_id":"","url":"https://api.github.com/users/timheap","html_url":"https://github.com/timheap","followers_url":"https://api.github.com/users/timheap/followers","following_url":"https://api.github.com/users/timheap/following{/other_user}","gists_url":"https://api.github.com/users/timheap/gists{/gist_id}","starred_url":"https://api.github.com/users/timheap/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/timheap/subscriptions","organizations_url":"https://api.github.com/users/timheap/orgs","repos_url":"https://api.github.com/users/timheap/repos","events_url":"https://api.github.com/users/timheap/events{/privacy}","received_events_url":"https://api.github.com/users/timheap/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/torchbox/wagtail/labels/For%20team%20discussion","name":"For team discussion","color":"009800"}],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":22,"created_at":"2014-06-25T06:52:37Z","updated_at":"2015-09-03T14:13:10Z","closed_at":"2015-09-03T14:13:10Z","body":"Sites often have user-editable content, like site title, tag line, contact details, etc. These should be accessible from the admin, should not be pages, and should only ever allow one instance of themselves (multiple site titles does not make sense!)\r\n\r\nThis sounds much like snippets, except for the single instance restriction, hence the 'singleton snippets'. Whether this is implemented using snippets is another matter entirely.\r\n\r\nI can think of multiple ways this functionality could be implemented, each with their own pros and cons:\r\n\r\n1. Extend snippets to allow singletons. This area of the admin already exists, and can be used for this kind of 'global' content that is not tied to a page. However, snippets would have to be modified to have a 'singleton' option, as well as some (potentially confusing and inconsistent) UI changes to handle this.\r\n\r\n2. Add a new section to the admin for 'site-wide settings', or something of the sort. Allow models to register themselves to the settings section, much like snippets. The UI (and possibly some model options) would enforce the singleton aspect. Other wagtail plugins can then register themselves to this system as well.\r\n\r\n3. Other approaches?\r\n\r\nPersonally, I prefer approach number 2. If the devs think this is a worthy feature, and a consensus on how to implement can be reached, I will develop it. "},"comment":{"url":"https://api.github.com/repos/torchbox/wagtail/issues/comments/137462405","html_url":"https://github.com/torchbox/wagtail/issues/368#issuecomment-137462405","issue_url":"https://api.github.com/repos/torchbox/wagtail/issues/368","id":137462405,"user":{"login":"timheap","id":132147,"avatar_url":"https://avatars.githubusercontent.com/u/132147?v=3","gravatar_id":"","url":"https://api.github.com/users/timheap","html_url":"https://github.com/timheap","followers_url":"https://api.github.com/users/timheap/followers","following_url":"https://api.github.com/users/timheap/following{/other_user}","gists_url":"https://api.github.com/users/timheap/gists{/gist_id}","starred_url":"https://api.github.com/users/timheap/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/timheap/subscriptions","organizations_url":"https://api.github.com/users/timheap/orgs","repos_url":"https://api.github.com/users/timheap/repos","events_url":"https://api.github.com/users/timheap/events{/privacy}","received_events_url":"https://api.github.com/users/timheap/received_events","type":"User","site_admin":false},"created_at":"2015-09-03T14:13:10Z","updated_at":"2015-09-03T14:13:10Z","body":"Closing in favour of [wagtailsettings](https://pypi.python.org/pypi/wagtailsettings/)"}}