File tree Expand file tree Collapse file tree 3 files changed +21
-0
lines changed
Expand file tree Collapse file tree 3 files changed +21
-0
lines changed Original file line number Diff line number Diff line change @@ -170,4 +170,17 @@ class UI {
170170 'to' : new Date ( document . getElementById ( 'dateTo' ) . value ) . toLocaleDateString ( )
171171 } ;
172172 }
173+
174+ fillListOfDays ( days ) {
175+ var parent = document . getElementById ( 'byDays' ) ;
176+ for ( var i = 0 ; i < days . length ; i ++ ) {
177+ var div = document . createElement ( 'div' ) ;
178+ div . classList . add ( 'day' ) ;
179+ var span = document . createElement ( 'span' ) ;
180+ span . innerHTML = days [ i ] ;
181+ div . appendChild ( span ) ;
182+
183+ parent . appendChild ( div ) ;
184+ }
185+ }
173186}
Original file line number Diff line number Diff line change @@ -185,4 +185,6 @@ function getTabsByDays(tabs){
185185 listOfDays = listOfDays . sort ( function ( a , b ) {
186186 return new Date ( a ) - new Date ( b ) ;
187187 } ) ;
188+
189+ ui . fillListOfDays ( listOfDays ) ;
188190}
Original file line number Diff line number Diff line change @@ -144,4 +144,10 @@ input[type="date"]{
144144 padding : 4px ;
145145 background-color : rgb (223 , 221 , 221 );
146146 text-align : center;
147+ }
148+
149+ .day {
150+ width : 500px ;
151+ height : 25px ;
152+ cursor : pointer;
147153}
You can’t perform that action at this time.
0 commit comments