You can also enable logging, see https://duet3d.dozuki.com/Wiki/GCode#Section_M929_Start_stop_event_logging_to_SD_card. When a print finishes, the time taken is written to the log.