Find date related to boolean line item

I have build a module with time over the columns and a flag as a line item. Now I want to extend this flag to an x amount of periods, starting from the date flagged in the current flag.


In order to do this I would like to find the date attached to the TRUE value of the flag, then sum the amount of periods to this date, and then create another flag. How can this be done?


Best Answer