|
|
|
@ -300,11 +300,16 @@ export class TimeTrackerService {
|
|
|
|
|
if (!this.currentRunHistory) return;
|
|
|
|
|
|
|
|
|
|
if (this.configService.config.enableStopwatch) {
|
|
|
|
|
if (!this.start || this.resumeOnNext) {
|
|
|
|
|
if(!this.isActive && this.resumeOnNext) {
|
|
|
|
|
this.resumeOnNext = false;
|
|
|
|
|
this.startStopwatch();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if(!this.isActive && !this.resumeOnNext) {
|
|
|
|
|
//Don't start timer if not meant to auto resumes on next.
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
this.pushSubject.next({
|
|
|
|
|
type: EntryType.ZoneEnter,
|
|
|
|
|
zone: zone,
|
|
|
|
@ -330,6 +335,7 @@ export class TimeTrackerService {
|
|
|
|
|
case Resume.Discard:
|
|
|
|
|
this.setCurrentRunHistory(this.createNew(plan.name));
|
|
|
|
|
plan.last_stored_time = this.currentRunHistory!.uuid;
|
|
|
|
|
this.resumeOnNext = true;
|
|
|
|
|
plan.requestSelfSave();
|
|
|
|
|
break;
|
|
|
|
|
}
|
|
|
|
|