{"action":"opened","issue":{"url":"https://api.github.com/repos/kartik-v/yii2-widget-datepicker/issues/31","labels_url":"https://api.github.com/repos/kartik-v/yii2-widget-datepicker/issues/31/labels{/name}","comments_url":"https://api.github.com/repos/kartik-v/yii2-widget-datepicker/issues/31/comments","events_url":"https://api.github.com/repos/kartik-v/yii2-widget-datepicker/issues/31/events","html_url":"https://github.com/kartik-v/yii2-widget-datepicker/issues/31","id":69935648,"number":31,"title":"Default value don't work in datapicker with Model","user":{"login":"cinghie","id":2445152,"avatar_url":"https://avatars.githubusercontent.com/u/2445152?v=3","gravatar_id":"","url":"https://api.github.com/users/cinghie","html_url":"https://github.com/cinghie","followers_url":"https://api.github.com/users/cinghie/followers","following_url":"https://api.github.com/users/cinghie/following{/other_user}","gists_url":"https://api.github.com/users/cinghie/gists{/gist_id}","starred_url":"https://api.github.com/users/cinghie/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cinghie/subscriptions","organizations_url":"https://api.github.com/users/cinghie/orgs","repos_url":"https://api.github.com/users/cinghie/repos","events_url":"https://api.github.com/users/cinghie/events{/privacy}","received_events_url":"https://api.github.com/users/cinghie/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-04-21T19:55:07Z","updated_at":"2015-04-21T19:55:07Z","closed_at":null,"body":"Hi kartik-v,\r\n\r\nthe default value don't work in datapicker with Model:\r\n \r\n<?= $form->field($model, 'created')->widget(DateTimePicker::classname(), [\r\n        'value' => '23-Feb-1982 10:01',\r\n\t'pluginOptions' => [\r\n\t\t'autoclose' => true,\r\n\t        'format'    => 'dd-M-yyyy hh:ii',\r\n\t\t'todayHighlight' => true,\r\n\t]\r\n]); ?>\r\n\r\nIf i do the same without Model work fine:\r\n\r\n<?php  echo '<label for=\"items-created\" class=\"control-label\">Created</label>';\r\n\techo DateTimePicker::widget([\r\n\t\t'model' => $model,\r\n\t\t'name'  => 'created',\r\n\t\t'value' => '23-Feb-1982 10:01',\r\n\t\t'pluginOptions' => [\r\n\t\t   \t'autoclose' => true,\r\n\t\t\t'format'    => 'dd-M-yyyy hh:ii',\r\n\t\t\t'todayHighlight' => true\r\n\t\t]\r\n\t]);?>"}}