issue-29 #30
@ -5,11 +5,7 @@
|
|||||||
</component>
|
</component>
|
||||||
<component name="ChangeListManager">
|
<component name="ChangeListManager">
|
||||||
<list default="true" id="3a869f59-290a-4ab2-b036-a878ce801bc4" name="Changes" comment="Load worked minutes when reloading dashboard">
|
<list default="true" id="3a869f59-290a-4ab2-b036-a878ce801bc4" name="Changes" comment="Load worked minutes when reloading dashboard">
|
||||||
<change afterPath="$PROJECT_DIR$/src/main/java/core/api/models/timemanager/taskSchedule/ScheduleStatus.java" afterDir="false" />
|
|
||||||
<change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
|
<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/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/api/models/timemanager/taskSchedule/ActiveMinutesInformation.java" beforeDir="false" />
|
|
||||||
<change beforePath="$PROJECT_DIR$/src/main/java/core/repositories/timemanager/BasicTaskScheduleRepository.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/main/java/core/repositories/timemanager/BasicTaskScheduleRepository.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" />
|
||||||
@ -107,7 +103,9 @@
|
|||||||
<workItem from="1698298897364" duration="4242000" />
|
<workItem from="1698298897364" duration="4242000" />
|
||||||
<workItem from="1698426430946" duration="665000" />
|
<workItem from="1698426430946" duration="665000" />
|
||||||
<workItem from="1698474363766" duration="3686000" />
|
<workItem from="1698474363766" duration="3686000" />
|
||||||
<workItem from="1698499063683" duration="7685000" />
|
<workItem from="1698499063683" duration="8312000" />
|
||||||
|
<workItem from="1698557538577" duration="18000" />
|
||||||
|
<workItem from="1698557567325" duration="1724000" />
|
||||||
</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" />
|
||||||
@ -271,6 +269,16 @@
|
|||||||
<line>52</line>
|
<line>52</line>
|
||||||
<option name="timeStamp" value="1" />
|
<option name="timeStamp" value="1" />
|
||||||
</line-breakpoint>
|
</line-breakpoint>
|
||||||
|
<line-breakpoint enabled="true" type="java-line">
|
||||||
|
<url>file://$PROJECT_DIR$/src/main/java/core/services/TaskScheduleService.java</url>
|
||||||
|
<line>86</line>
|
||||||
|
<option name="timeStamp" value="5" />
|
||||||
|
</line-breakpoint>
|
||||||
|
<line-breakpoint enabled="true" type="java-line">
|
||||||
|
<url>file://$PROJECT_DIR$/src/main/java/core/services/TaskScheduleService.java</url>
|
||||||
|
<line>93</line>
|
||||||
|
<option name="timeStamp" value="6" />
|
||||||
|
</line-breakpoint>
|
||||||
</breakpoints>
|
</breakpoints>
|
||||||
</breakpoint-manager>
|
</breakpoint-manager>
|
||||||
</component>
|
</component>
|
||||||
|
@ -32,7 +32,7 @@ public class RecursiveTaskgroupInfo {
|
|||||||
|
|
||||||
for(Task task : taskgroup.getActiveTasks()) {
|
for(Task task : taskgroup.getActiveTasks()) {
|
||||||
this.activeTasks.add(new TaskOverviewInfo(task));
|
this.activeTasks.add(new TaskOverviewInfo(task));
|
||||||
if(task.getDeadline().isBefore(LocalDate.now())) {
|
if(task.getDeadline() != null && task.getDeadline().isBefore(LocalDate.now())) {
|
||||||
this.hasOverdueTask = true;
|
this.hasOverdueTask = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -28,7 +28,9 @@ public class TaskEntityInfo {
|
|||||||
this.eta = task.getEta();
|
this.eta = task.getEta();
|
||||||
this.startDate = task.getStartDate();
|
this.startDate = task.getStartDate();
|
||||||
this.deadline = task.getDeadline();
|
this.deadline = task.getDeadline();
|
||||||
this.overdue = LocalDate.now().isAfter(task.getDeadline());
|
if(task.getDeadline() != null) {
|
||||||
|
this.overdue = LocalDate.now().isAfter(task.getDeadline());
|
||||||
|
}
|
||||||
this.finished = task.isFinished();
|
this.finished = task.isFinished();
|
||||||
this.workTime = task.getWorkTime();
|
this.workTime = task.getWorkTime();
|
||||||
}
|
}
|
||||||
|
@ -19,7 +19,9 @@ public class TaskOverviewInfo {
|
|||||||
this.activeMinutes = task.getWorkTime();
|
this.activeMinutes = task.getWorkTime();
|
||||||
this.eta = task.getEta();
|
this.eta = task.getEta();
|
||||||
this.limit = task.getDeadline();
|
this.limit = task.getDeadline();
|
||||||
this.overdue = LocalDate.now().isAfter(task.getDeadline());
|
if(task.getDeadline() != null) {
|
||||||
|
this.overdue = LocalDate.now().isAfter(task.getDeadline());
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public long getTaskID() {
|
public long getTaskID() {
|
||||||
|
@ -82,7 +82,8 @@ public class TaskScheduleService {
|
|||||||
|
|
||||||
public ServiceResult<BasicTaskSchedule> scheduleTaskNow(Task task) {
|
public ServiceResult<BasicTaskSchedule> scheduleTaskNow(Task task) {
|
||||||
//Check if task has already an active schedule
|
//Check if task has already an active schedule
|
||||||
if(task.hasActiveSchedule()) {
|
ServiceResult<BasicTaskSchedule> activeSchedule = getActiveSchedule(task.getTaskgroup().getUser().getUsername());
|
||||||
|
if(task.hasActiveSchedule() || activeSchedule.getExitCode() != ServiceExitCode.MISSING_ENTITY) {
|
||||||
return new ServiceResult<>(ServiceExitCode.ENTITY_ALREADY_EXIST);
|
return new ServiceResult<>(ServiceExitCode.ENTITY_ALREADY_EXIST);
|
||||||
} else {
|
} else {
|
||||||
BasicTaskSchedule basicTaskSchedule = new BasicTaskSchedule(task, LocalDate.now());
|
BasicTaskSchedule basicTaskSchedule = new BasicTaskSchedule(task, LocalDate.now());
|
||||||
|
@ -72,11 +72,13 @@ export class TaskEditorComponent implements OnInit {
|
|||||||
}
|
}
|
||||||
|
|
||||||
editTask() {
|
editTask() {
|
||||||
|
const startingDate = this.startDate.value.length == 0? null:this.startDate.value.length
|
||||||
|
const deadline = this.endDate.value.length == 0? null:this.endDate.value.length
|
||||||
this.taskService.tasksTaskIDPost(this.editorData.task!.taskID, {
|
this.taskService.tasksTaskIDPost(this.editorData.task!.taskID, {
|
||||||
taskName: this.nameCtrl.value,
|
taskName: this.nameCtrl.value,
|
||||||
eta: this.etaCtrl.value,
|
eta: this.etaCtrl.value,
|
||||||
startDate: this.startDate.value,
|
startDate: startingDate,
|
||||||
deadline: this.endDate.value
|
deadline: deadline
|
||||||
}).subscribe({
|
}).subscribe({
|
||||||
next: resp => {
|
next: resp => {
|
||||||
this.editorData.task!.taskName = this.nameCtrl.value;
|
this.editorData.task!.taskName = this.nameCtrl.value;
|
||||||
|
Loading…
Reference in New Issue
Block a user