webapp/models.py
def change_status(self, target_status):
        """
        changes the timebox to the desired status
        if the target status is Done then all non-done tasks in the timebox
        will be returned to the Backlog
        """
        backlog = db.session.query(Timebox).filter(Timebox.title=='Backlog').filter(Timebox.project_id==self.project_id).first()
        for task in self.tasks.all():
            if task.status != 'Done':
                task.add_to_timebox(backlog)
        self.status = target_status
        db.session.add(self)
        db.session.commit()

        changes the timebox to the desired status
        if the target status is Done then all non-done tasks in the timebox
        will be returned to the Backlog
        
changes the timebox to the desired status
if the target status is Done then all non-done tasks in the timebox
will be returned to the Backlog
changes the timebox to the desired status if the target status is Done then all non - done tasks in the timebox will be returned to the Backlog
def change_status(self, target_status):
        backlog = db.session.query(Timebox).filter(Timebox.title=='Backlog').filter(Timebox.project_id==self.project_id).first()
        for task in self.tasks.all():
            if task.status != 'Done':
                task.add_to_timebox(backlog)
        self.status = target_status
        db.session.add(self)
        db.session.commit()
def change_status ( self , target_status ) : backlog = db . session . query ( Timebox ) . filter ( Timebox . title == 'Backlog' ) . filter ( Timebox . project_id == self . project_id ) . first ( ) for task in self . tasks . all ( ) : if task . status != 'Done' : task . add_to_timebox ( backlog ) self . status = target_status db . session . add ( self ) db . session . commit ( )
changes the timebox to the desired status
if the target status is Done then all non-done tasks in the timebox
will be returned to the Backlog
changes the timebox to the desired status if the target status is Done then all non - done tasks in the timebox will be returned to the Backlog
"""
        changes the timebox to the desired status
        if the target status is Done then all non-done tasks in the timebox
        will be returned to the Backlog
        """
self
target_status