fix if/else
automatic start/end_time for reports