Greetings, I have a problem in my controller with AngularJS , I have an object that brings me the following
Objeto{
FechaInicio: "2017-11-04"
FechaTermino: "2017-03-04"
}
I need the way you tell me the last dates of the month that exist in that time interval and I create a new new list that should look something like this:
nuevaLista {
fechaFin[0]: 2017-11-30, //(30 dias)
fechaFin[1]: 2017-12-31, //(31 días)
fechaFin[2]: 2018-01-01, //(31 días)
fechaFin[3]: 2018-02-28, //(28 días o 29 si aplica)
}
I'm reviewing the library moment (moment().endOf(String);)
but I do not know how to do it so that it calculates only in that interval.