Is there build-in function in frappe to add days to 25-02-2017 -> 26-03-2017?

Is there build-in function in frappe to add days to 25-02-2017 -> 26-03-2017?
25-03-2017 -> 26-04-2017
25-04-2017 -> 26-05-2017

for payroll purpose.

@magic-overflow,

Yes, use the add_days or add_to_date method.

You can find this method in data.py

1 Like

if add 30day to a date which end 30, it works correctly.
But if date end 31, it not right.
ex: 25-07-2017 - 25-08-2017

Function works perfectly fine but not in my case. I am trying to find a function that can do as I explain above.

you can check if there is a function to add 1 month instead of days or write your own function :grin:

1 Like

Yes, i may add a day and a month. :smiley:

Can we insert this function from the DocType now that the v13 Frappe is much more complex? Like display 14 days more in field “autoclose” on top of date from “startdate” field? :slight_smile: