DFO-1651
Fixed update of permit status. Permits now correctly track changes of statuses of their assigned forms and change their own statuses accordingly.