File tree Expand file tree Collapse file tree 2 files changed +25
-3
lines changed Expand file tree Collapse file tree 2 files changed +25
-3
lines changed Original file line number Diff line number Diff line change 77 < link rel ="icon " type ="image/png " href ="favicon.png " />
88 < meta name ="viewport " content ="width=device-width, initial-scale=1 ">
99 < link href ="https://fonts.googleapis.com/css?family=Roboto:400,500 " rel ="stylesheet " type ="text/css ">
10+ < link href ="https://fonts.googleapis.com/icon?family=Material+Icons " rel ="stylesheet ">
1011 < link href ="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.9.0/styles/github.min.css " rel ="stylesheet ">
1112 < link href ="https://cdnjs.cloudflare.com/ajax/libs/angular-material/1.1.4/angular-material.min.css " rel ="stylesheet " type ="text/css "/>
1213 < link rel ="stylesheet " href ="./css/material-datetimepicker.css " type ="text/css "/>
@@ -159,19 +160,29 @@ <h2>Datetime Pickers</h2>
159160 </ div >
160161
161162 < div layout-gt-md ="row " layout ="column " layout-align-gt-md ="center center ">
162-
163163 < div flex-gt-md ="30 ">
164164 < p > mdcDateTimeDialog Service</ p >
165165 < md-button class ="md-raised md-primary " ng-click ="displayDialog() ">
166166 Display Picker
167167 </ md-button >
168168 < p ng-if ="selectedDateTime "> Date: {{selectedDateTime|date}}</ p >
169169 </ div >
170-
171170 < div flex-gt-md ="grow " ex-source-code target ="button "> </ div >
172-
173171 </ div >
174172
173+ < br >
174+ < label > mdcDateTimeDialog Service Input</ label >
175+ < div layout-gt-md ="row " layout ="column " layout-align-gt-md ="center center ">
176+ < div layout ="row " flex-gt-md ="30 " layout-align ="start center ">
177+ < md-input-container md-float >
178+ < input type ="date " ng-model ="selectedDateTimeIn " id ="dateinput ">
179+ </ md-input-container >
180+ < md-button class ="md-primary md-icon-button " style ="top:-12px;left:-12px; " ng-click ="displayDialogIn() ">
181+ < md-icon class ="material-icons "> today</ md-icon >
182+ </ md-button >
183+ </ div >
184+ < div flex-gt-md ="grow " ex-source-code target ="input "> </ div >
185+ </ div >
175186 </ md-card-content >
176187
177188 </ md-card >
Original file line number Diff line number Diff line change 5353 } ) ;
5454 } ;
5555
56+ $scope . displayDialogIn = function ( ) {
57+ mdcDateTimeDialog . show ( {
58+ currentDate : $scope . selectedDateTimeIn || moment ( ) . startOf ( 'day' ) ,
59+ maxDate : $scope . maxDate ,
60+ time : false
61+ } )
62+ . then ( function ( date ) {
63+ $scope . selectedDateTimeIn = date ;
64+ } ) ;
65+ } ;
66+
5667 // Set and change the text direction
5768 $scope . txtdir = document . documentElement . dir || 'ltr' ;
5869 $scope . changeDir = function ( ) {
You can’t perform that action at this time.
0 commit comments