changed addDays function and cashflow functionality