Closed SadovovAlex closed 7 years ago
and your pikaday-invocation looks like this?
<pikaday [(day)]="DateFrom">
Gesendet: Montag, 22. Mai 2017 um 09:00 Uhr Von: Alex notifications@github.com An: simon-void/pikaday_datepicker_angular2 pikaday_datepicker_angular2@noreply.github.com Cc: Subscribed subscribed@noreply.github.com Betreff: [simon-void/pikaday_datepicker_angular2] only Init update two way variable "day" (#2)
Hi
only Init update two way variable "day": if i set variable in init variable `class AppComponent_export1c implements OnInit { final Router _router; AppComponent_export1c(this._router);
DateTime DateFrom = new DateTime.now(); `
all ok
but if i set it on click button, is not set in pikaday=(
` template
Дата с: {{DateFrom}}
<button class="btn btn-primary" title="zzzzz" (click)="onClickView()"> zzzzz
dart onClickView() async { DateTime today = new DateTime.now(); DateFrom = new DateTime(today.year, today.month-1, 1); print("Datefrom=" + DateFrom.toString() ); }
`
where i mistake?
PS var {{DateFrom}} in a template is set OK
— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub, or mute the thread.
oh, not paste all template
<label>Дата с:</label>
<pikaday cssClasses="form-control input-sm" [(day)]="DateFrom" format="DD-MM-YYYY"
minDate="2017-01-01" maxDate="2025-12-31"
firstDay="1">
</pikaday>
{{DateFrom}}
I'm working on fixing that. Maybe today, maybe on wednesday.
/Stephan
Gesendet: Montag, 22. Mai 2017 um 09:42 Uhr Von: Alex notifications@github.com An: simon-void/pikaday_datepicker_angular2 pikaday_datepicker_angular2@noreply.github.com Cc: "Stephan Schröder" simon.void@gmx.de, Comment comment@noreply.github.com Betreff: Re: [simon-void/pikaday_datepicker_angular2] only Init update two way variable "day" (#2)
oh, not paste all template
check out version 2.1.1
Hi
only Init update two way variable "day": if i set variable in init variable `class AppComponent_export1c implements OnInit { final Router _router; AppComponent_export1c(this._router);
DateTime DateFrom = new DateTime.now(); `
all ok
but if i set it on click button, is not set in pikaday=(
template
dart onClickView() async { DateTime today = new DateTime.now(); DateFrom = new DateTime(today.year, today.month-1, 1); print("Datefrom=" + DateFrom.toString() ); }
`
where i mistake?
PS var {{DateFrom}} in a template is set OK