File tree 2 files changed +14
-0
lines changed
2 files changed +14
-0
lines changed Original file line number Diff line number Diff line change 165
165
.editar-atividade > form {
166
166
flex-direction : column;
167
167
}
168
+
169
+ input [type = "date" ]{
170
+ width : 100% ;
171
+ }
168
172
}
Original file line number Diff line number Diff line change @@ -19,6 +19,13 @@ function construirFormularioNovo(){
19
19
inputDataAtividade . type = 'date' ;
20
20
inputDataAtividade . required = true ;
21
21
inputDataAtividade . placeholder = "Informe a data" ;
22
+
23
+ let dataAtual = new Date ( ) ;
24
+ let dataAtualFormat = dataAtual . toISOString ( ) . substr ( 0 , 10 ) ;
25
+
26
+ inputDataAtividade . setAttribute ( "value" , dataAtualFormat ) ;
27
+ inputDataAtividade . innerText = dataAtualFormat ;
28
+
22
29
botao . textContent = 'Adicionar' ;
23
30
botao . type = 'submit' ;
24
31
formulario . appendChild ( inputAtividade ) ;
@@ -98,6 +105,9 @@ function main(){
98
105
atualizar ( ) ;
99
106
inputAtividade . value = "" ;
100
107
inputDataAtividade . value = "" ;
108
+ let dataA = new Date ( ) ;
109
+ let dataAFormat = dataA . toISOString ( ) . substr ( 0 , 10 ) ;
110
+ inputDataAtividade . value = dataAFormat ;
101
111
selectTagsPrioridade . value = 0 ;
102
112
} ) ;
103
113
}
You can’t perform that action at this time.
0 commit comments