{"action":"closed","issue":{"url":"https://api.github.com/repos/WebDevStudios/CMB2/issues/816","repository_url":"https://api.github.com/repos/WebDevStudios/CMB2","labels_url":"https://api.github.com/repos/WebDevStudios/CMB2/issues/816/labels{/name}","comments_url":"https://api.github.com/repos/WebDevStudios/CMB2/issues/816/comments","events_url":"https://api.github.com/repos/WebDevStudios/CMB2/issues/816/events","html_url":"https://github.com/WebDevStudios/CMB2/issues/816","id":194717465,"number":816,"title":"Ability to define defaults for subfields of complex fields","user":{"login":"slaFFik","id":282234,"avatar_url":"https://avatars3.githubusercontent.com/u/282234?v=3","gravatar_id":"","url":"https://api.github.com/users/slaFFik","html_url":"https://github.com/slaFFik","followers_url":"https://api.github.com/users/slaFFik/followers","following_url":"https://api.github.com/users/slaFFik/following{/other_user}","gists_url":"https://api.github.com/users/slaFFik/gists{/gist_id}","starred_url":"https://api.github.com/users/slaFFik/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/slaFFik/subscriptions","organizations_url":"https://api.github.com/users/slaFFik/orgs","repos_url":"https://api.github.com/users/slaFFik/repos","events_url":"https://api.github.com/users/slaFFik/events{/privacy}","received_events_url":"https://api.github.com/users/slaFFik/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2016-12-09T22:57:50Z","updated_at":"2017-04-03T20:26:49Z","closed_at":"2017-04-03T20:26:49Z","body":"### Expected Behavior:\r\nAbility to define defaults for individual subfields in complex fields, like `text_datetime_timestamp_timezone`.\r\n\r\nPossible syntax:\r\n\r\n```php\r\n$section->add_field( array(\r\n                         'name'        => 'Field Name',\r\n                         'id'          => self::PREFIX . 'date_time_tz',\r\n                         'type'        => 'text_datetime_timestamp_timezone',\r\n                         'default'      => array(\r\n                             'select_timezone' => \\CMB2_Utils::timezone_string()\r\n                         )\r\n                     ) );\r\n```\r\n\r\n### Actual Behavior:\r\n\r\nCurrently it's impossible to define defaults for fields, which consists of subfields of different types."}}
{"actor":{"display_login":"bradp"}}