import { Injectable } from '@angular/core';
import moment = require('moment');
@Injectable()
export class DateRangeHelper extends Date {
constructor( ) {
super();
}
/**
* wait for it
*/
addDays(days: number) {
console.log('Days =', days);
let date = new Date(this.valueOf());
console.log('this.valueOf = ', this.valueOf());
console.log('date 1 = ', date);
date.setDate(date.getDate() + days);
console.log('date 2 = ', date);
return date;
}
getDates(startDate: any, stopDate: any) {
console.log('startDate: = ', startDate);