Clear Worktime/ActiveTime Code
This commit is contained in:
parent
bcc9b4760f
commit
8b7354de51
@ -5,7 +5,6 @@
|
|||||||
</component>
|
</component>
|
||||||
<component name="ChangeListManager">
|
<component name="ChangeListManager">
|
||||||
<list default="true" id="3a869f59-290a-4ab2-b036-a878ce801bc4" name="Changes" comment="Remove update spamming in console">
|
<list default="true" id="3a869f59-290a-4ab2-b036-a878ce801bc4" name="Changes" comment="Remove update spamming in console">
|
||||||
<change beforePath="$PROJECT_DIR$/src/main/java/core/api/controller/ScheduleController.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/main/java/core/api/controller/ScheduleController.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/java/core/services/TaskScheduleService.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/main/java/core/services/TaskScheduleService.java" afterDir="false" />
|
||||||
</list>
|
</list>
|
||||||
<option name="SHOW_DIALOG" value="false" />
|
<option name="SHOW_DIALOG" value="false" />
|
||||||
@ -100,7 +99,7 @@
|
|||||||
<workItem from="1698127431684" duration="2039000" />
|
<workItem from="1698127431684" duration="2039000" />
|
||||||
<workItem from="1698164397550" duration="2329000" />
|
<workItem from="1698164397550" duration="2329000" />
|
||||||
<workItem from="1698246651541" duration="5106000" />
|
<workItem from="1698246651541" duration="5106000" />
|
||||||
<workItem from="1698298897364" duration="3634000" />
|
<workItem from="1698298897364" duration="4242000" />
|
||||||
</task>
|
</task>
|
||||||
<task id="LOCAL-00001" summary="Structure Taskgroups in Hierarchies">
|
<task id="LOCAL-00001" summary="Structure Taskgroups in Hierarchies">
|
||||||
<option name="closed" value="true" />
|
<option name="closed" value="true" />
|
||||||
@ -248,11 +247,6 @@
|
|||||||
<line>167</line>
|
<line>167</line>
|
||||||
<option name="timeStamp" value="4" />
|
<option name="timeStamp" value="4" />
|
||||||
</line-breakpoint>
|
</line-breakpoint>
|
||||||
<line-breakpoint enabled="true" type="java-line">
|
|
||||||
<url>file://$PROJECT_DIR$/src/main/java/core/services/TaskScheduleService.java</url>
|
|
||||||
<line>125</line>
|
|
||||||
<option name="timeStamp" value="7" />
|
|
||||||
</line-breakpoint>
|
|
||||||
</breakpoints>
|
</breakpoints>
|
||||||
</breakpoint-manager>
|
</breakpoint-manager>
|
||||||
</component>
|
</component>
|
||||||
|
@ -122,9 +122,8 @@ public class TaskScheduleService {
|
|||||||
|
|
||||||
taskSchedule.setFinishedTime(LocalDateTime.now());
|
taskSchedule.setFinishedTime(LocalDateTime.now());
|
||||||
long activeTime = Duration.between(taskSchedule.getStartTime(), taskSchedule.getFinishedTime()).toMinutes();
|
long activeTime = Duration.between(taskSchedule.getStartTime(), taskSchedule.getFinishedTime()).toMinutes();
|
||||||
long workTime = (taskSchedule.getTask().getWorkTime() + activeTime);
|
long workTime = taskSchedule.getTask().getWorkTime() + activeTime;
|
||||||
int workTime_i = (int) (workTime);
|
taskSchedule.getTask().setWorkTime((int) workTime);
|
||||||
taskSchedule.getTask().setWorkTime(workTime_i);
|
|
||||||
if(finish) {
|
if(finish) {
|
||||||
taskSchedule.getTask().setFinished(true);
|
taskSchedule.getTask().setFinished(true);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user