Skip to content

Commit

Permalink
docs(module:date-picker): remove unneeded variable (#5786)
Browse files Browse the repository at this point in the history
  • Loading branch information
Depickere Sven authored Sep 16, 2020
1 parent bb8677c commit a1a58fd
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions components/date-picker/demo/presetted-ranges.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@ import endOfMonth from 'date-fns/endOfMonth';
@Component({
selector: 'nz-demo-date-picker-presetted-ranges',
template: `
<nz-range-picker [nzRanges]="ranges1" ngModel (ngModelChange)="onChange($event)"></nz-range-picker>
<nz-range-picker [nzRanges]="ranges" ngModel (ngModelChange)="onChange($event)"></nz-range-picker>
<br />
<nz-range-picker
[nzRanges]="ranges1"
[nzRanges]="ranges"
nzShowTime
nzFormat="yyyy/MM/dd HH:mm:ss"
ngModel
Expand All @@ -26,8 +26,7 @@ import endOfMonth from 'date-fns/endOfMonth';
]
})
export class NzDemoDatePickerPresettedRangesComponent {
ranges1 = { Today: [new Date(), new Date()], 'This Month': [new Date(), endOfMonth(new Date())] };
ranges2 = { Today: [new Date(), new Date()], 'This Month': [new Date(), endOfMonth(new Date())] };
ranges = { Today: [new Date(), new Date()], 'This Month': [new Date(), endOfMonth(new Date())] };

onChange(result: Date[]): void {
console.log('From: ', result[0], ', to: ', result[1]);
Expand Down

0 comments on commit a1a58fd

Please sign in to comment.