issue-20 #46

Merged
sebastian merged 15 commits from issue-20 into master 2023-11-12 13:18:53 +01:00
3 changed files with 24 additions and 12 deletions
Showing only changes of commit d9013174f4 - Show all commits

View File

@ -4,15 +4,10 @@
<option name="autoReloadType" value="SELECTIVE" />
</component>
<component name="ChangeListManager">
<list default="true" id="3a869f59-290a-4ab2-b036-a878ce801bc4" name="Changes" comment="Adapt datetime-picker">
<list default="true" id="3a869f59-290a-4ab2-b036-a878ce801bc4" name="Changes" comment="Fix wrong date">
<change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/src/main/java/core/entities/timemanager/AdvancedTaskSchedule.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/main/java/core/entities/timemanager/AdvancedTaskSchedule.java" afterDir="false" />
<change beforePath="$PROJECT_DIR$/src/main/java/core/services/TaskScheduleService.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/main/java/core/services/TaskScheduleService.java" afterDir="false" />
<change beforePath="$PROJECT_DIR$/src/main/resources/application.properties" beforeDir="false" afterPath="$PROJECT_DIR$/src/main/resources/application.properties" afterDir="false" />
<change beforePath="$PROJECT_DIR$/../frontend/src/app/date-time-picker/date-time-picker.component.ts" beforeDir="false" afterPath="$PROJECT_DIR$/../frontend/src/app/date-time-picker/date-time-picker.component.ts" afterDir="false" />
<change beforePath="$PROJECT_DIR$/../frontend/src/app/schedules/advanced-scheduler/advanced-scheduler.component.ts" beforeDir="false" afterPath="$PROJECT_DIR$/../frontend/src/app/schedules/advanced-scheduler/advanced-scheduler.component.ts" afterDir="false" />
<change beforePath="$PROJECT_DIR$/../frontend/src/app/schedules/scheduler/scheduler.component.ts" beforeDir="false" afterPath="$PROJECT_DIR$/../frontend/src/app/schedules/scheduler/scheduler.component.ts" afterDir="false" />
<change beforePath="$PROJECT_DIR$/../openapi.yaml" beforeDir="false" afterPath="$PROJECT_DIR$/../openapi.yaml" afterDir="false" />
</list>
<option name="SHOW_DIALOG" value="false" />
<option name="HIGHLIGHT_CONFLICTS" value="true" />
@ -223,7 +218,7 @@
<workItem from="1699473376129" duration="1423000" />
<workItem from="1699639316405" duration="9267000" />
<workItem from="1699684493731" duration="1121000" />
<workItem from="1699769541677" duration="6476000" />
<workItem from="1699769541677" duration="7576000" />
</task>
<task id="LOCAL-00001" summary="Structure Taskgroups in Hierarchies">
<option name="closed" value="true" />
@ -545,14 +540,21 @@
<option name="project" value="LOCAL" />
<updated>1699783968670</updated>
</task>
<option name="localTasksCounter" value="41" />
<task id="LOCAL-00041" summary="Fix wrong date">
<option name="closed" value="true" />
<created>1699786723938</created>
<option name="number" value="00041" />
<option name="presentableId" value="LOCAL-00041" />
<option name="project" value="LOCAL" />
<updated>1699786723938</updated>
</task>
<option name="localTasksCounter" value="42" />
<servers />
</component>
<component name="TypeScriptGeneratedFilesManager">
<option name="version" value="3" />
</component>
<component name="VcsManagerConfiguration">
<MESSAGE value="Check if there is another active schedule when starting task now" />
<MESSAGE value="List missed Schedules" />
<MESSAGE value="Forget single schedule" />
<MESSAGE value="Fix marking finished task as overdue" />
@ -577,7 +579,8 @@
<MESSAGE value="ScheduleNow test with running advanced Schedule" />
<MESSAGE value="Update values of datetime picker automatically for editing" />
<MESSAGE value="Adapt datetime-picker" />
<option name="LAST_COMMIT_MESSAGE" value="Adapt datetime-picker" />
<MESSAGE value="Fix wrong date" />
<option name="LAST_COMMIT_MESSAGE" value="Fix wrong date" />
</component>
<component name="XDebuggerManager">
<breakpoint-manager>

View File

@ -69,6 +69,6 @@ public class AdvancedTaskSchedule extends AbstractSchedule {
@Override
public boolean isMissed(LocalDateTime timeReference) {
return startTime == null && scheduleEnd.isBefore(timeReference);
return startTime == null && scheduleEnd.toLocalDate().isBefore(timeReference.toLocalDate());
}
}

View File

@ -115,7 +115,16 @@ public class TaskScheduleService {
}
}
} else {
//to continue...
if(((AdvancedTaskSchedule) abstractSchedule).getScheduleStart().toLocalDate().isEqual(LocalDate.now())) {
//Schedule is today
if(startable && abstractSchedule.getStartTime() == null) {
if(abstractSchedule.getStartTime() == null) {
filteredSchedules.add(abstractSchedule);
}
} else if(!startable) {
filteredSchedules.add(abstractSchedule);
}
}
}
}
return filteredSchedules;