Add information on workedTime, added Scheduler Component
This commit is contained in:
parent
6f5397d8f8
commit
e6117d1f7e
@ -5,13 +5,8 @@
|
|||||||
</component>
|
</component>
|
||||||
<component name="ChangeListManager">
|
<component name="ChangeListManager">
|
||||||
<list default="true" id="3a869f59-290a-4ab2-b036-a878ce801bc4" name="Changes" comment="Define Entity BasicTaskSchedule and Taskcontroller">
|
<list default="true" id="3a869f59-290a-4ab2-b036-a878ce801bc4" name="Changes" comment="Define Entity BasicTaskSchedule and Taskcontroller">
|
||||||
<change afterPath="$PROJECT_DIR$/src/main/java/core/api/models/timemanager/taskSchedule/BasicTaskScheduleEntityInfo.java" afterDir="false" />
|
|
||||||
<change afterPath="$PROJECT_DIR$/src/main/java/core/api/models/timemanager/taskSchedule/BasicTaskScheduleFieldInfo.java" afterDir="false" />
|
|
||||||
<change afterPath="$PROJECT_DIR$/src/main/java/core/repositories/timemanager/BasicTaskScheduleRepository.java" afterDir="false" />
|
|
||||||
<change afterPath="$PROJECT_DIR$/src/main/java/core/services/TaskScheduleService.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/tasks/TaskEntityInfo.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/main/java/core/api/models/timemanager/tasks/TaskEntityInfo.java" afterDir="false" />
|
||||||
<change beforePath="$PROJECT_DIR$/src/main/java/core/api/controller/TaskController.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/main/java/core/api/controller/TaskController.java" afterDir="false" />
|
|
||||||
<change beforePath="$PROJECT_DIR$/src/main/java/core/entities/timemanager/Task.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/main/java/core/entities/timemanager/Task.java" afterDir="false" />
|
<change beforePath="$PROJECT_DIR$/src/main/java/core/entities/timemanager/Task.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/main/java/core/entities/timemanager/Task.java" afterDir="false" />
|
||||||
</list>
|
</list>
|
||||||
<option name="SHOW_DIALOG" value="false" />
|
<option name="SHOW_DIALOG" value="false" />
|
||||||
@ -48,31 +43,31 @@
|
|||||||
<option name="hideEmptyMiddlePackages" value="true" />
|
<option name="hideEmptyMiddlePackages" value="true" />
|
||||||
<option name="showLibraryContents" value="true" />
|
<option name="showLibraryContents" value="true" />
|
||||||
</component>
|
</component>
|
||||||
<component name="PropertiesComponent"><![CDATA[{
|
<component name="PropertiesComponent">{
|
||||||
"keyToString": {
|
"keyToString": {
|
||||||
"RequestMappingsPanelOrder0": "0",
|
"RequestMappingsPanelOrder0": "0",
|
||||||
"RequestMappingsPanelOrder1": "1",
|
"RequestMappingsPanelOrder1": "1",
|
||||||
"RequestMappingsPanelWidth0": "75",
|
"RequestMappingsPanelWidth0": "75",
|
||||||
"RequestMappingsPanelWidth1": "75",
|
"RequestMappingsPanelWidth1": "75",
|
||||||
"RunOnceActivity.OpenProjectViewOnStart": "true",
|
"RunOnceActivity.OpenProjectViewOnStart": "true",
|
||||||
"RunOnceActivity.ShowReadmeOnStart": "true",
|
"RunOnceActivity.ShowReadmeOnStart": "true",
|
||||||
"WebServerToolWindowFactoryState": "false",
|
"WebServerToolWindowFactoryState": "false",
|
||||||
"git-widget-placeholder": "issue-11-angular-update",
|
"git-widget-placeholder": "issue-11-angular-update",
|
||||||
"last_directory_selection": "D:/Programmierprojekte/TimeManager/backend/src/main/java/core/api/models/timemanager",
|
"last_directory_selection": "D:/Programmierprojekte/TimeManager/backend/src/main/java/core/api/models/timemanager",
|
||||||
"last_opened_file_path": "D:/Programmierprojekte/Dicewars/client",
|
"last_opened_file_path": "D:/Programmierprojekte/Dicewars/client",
|
||||||
"node.js.detected.package.eslint": "true",
|
"node.js.detected.package.eslint": "true",
|
||||||
"node.js.detected.package.tslint": "true",
|
"node.js.detected.package.tslint": "true",
|
||||||
"node.js.selected.package.eslint": "(autodetect)",
|
"node.js.selected.package.eslint": "(autodetect)",
|
||||||
"node.js.selected.package.tslint": "(autodetect)",
|
"node.js.selected.package.tslint": "(autodetect)",
|
||||||
"settings.editor.selected.configurable": "swagger",
|
"settings.editor.selected.configurable": "swagger",
|
||||||
"vue.rearranger.settings.migration": "true"
|
"vue.rearranger.settings.migration": "true"
|
||||||
},
|
},
|
||||||
"keyToStringList": {
|
"keyToStringList": {
|
||||||
"DatabaseDriversLRU": [
|
"DatabaseDriversLRU": [
|
||||||
"mariadb"
|
"mariadb"
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
}]]></component>
|
}</component>
|
||||||
<component name="RunManager">
|
<component name="RunManager">
|
||||||
<configuration name="DemoApplication" type="SpringBootApplicationConfigurationType" factoryName="Spring Boot" nameIsGenerated="true">
|
<configuration name="DemoApplication" type="SpringBootApplicationConfigurationType" factoryName="Spring Boot" nameIsGenerated="true">
|
||||||
<module name="demo" />
|
<module name="demo" />
|
||||||
@ -99,7 +94,8 @@
|
|||||||
<workItem from="1697958018921" duration="91000" />
|
<workItem from="1697958018921" duration="91000" />
|
||||||
<workItem from="1697958118995" duration="5749000" />
|
<workItem from="1697958118995" duration="5749000" />
|
||||||
<workItem from="1697969480767" duration="6407000" />
|
<workItem from="1697969480767" duration="6407000" />
|
||||||
<workItem from="1697989716016" duration="3813000" />
|
<workItem from="1697989716016" duration="3814000" />
|
||||||
|
<workItem from="1698067098771" duration="307000" />
|
||||||
</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" />
|
||||||
|
@ -20,6 +20,8 @@ public class TaskEntityInfo {
|
|||||||
|
|
||||||
private boolean finished;
|
private boolean finished;
|
||||||
|
|
||||||
|
private int workTime;
|
||||||
|
|
||||||
public TaskEntityInfo(Task task) {
|
public TaskEntityInfo(Task task) {
|
||||||
this.taskID = task.getTaskID();
|
this.taskID = task.getTaskID();
|
||||||
this.taskName = task.getTaskName();
|
this.taskName = task.getTaskName();
|
||||||
@ -28,6 +30,7 @@ public class TaskEntityInfo {
|
|||||||
this.deadline = task.getDeadline();
|
this.deadline = task.getDeadline();
|
||||||
this.overdue = LocalDate.now().isAfter(task.getDeadline());
|
this.overdue = LocalDate.now().isAfter(task.getDeadline());
|
||||||
this.finished = task.isFinished();
|
this.finished = task.isFinished();
|
||||||
|
this.workTime = task.getWorkTime();
|
||||||
}
|
}
|
||||||
|
|
||||||
public long getTaskID() {
|
public long getTaskID() {
|
||||||
@ -85,4 +88,12 @@ public class TaskEntityInfo {
|
|||||||
public void setFinished(boolean finished) {
|
public void setFinished(boolean finished) {
|
||||||
this.finished = finished;
|
this.finished = finished;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public int getWorkTime() {
|
||||||
|
return workTime;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setWorkTime(int workTime) {
|
||||||
|
this.workTime = workTime;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -29,6 +29,8 @@ public class Task {
|
|||||||
@OneToMany(mappedBy = "task", cascade = CascadeType.ALL, fetch = FetchType.EAGER)
|
@OneToMany(mappedBy = "task", cascade = CascadeType.ALL, fetch = FetchType.EAGER)
|
||||||
private Set<BasicTaskSchedule> basicTaskSchedules;
|
private Set<BasicTaskSchedule> basicTaskSchedules;
|
||||||
|
|
||||||
|
private int workTime;
|
||||||
|
|
||||||
public Task(Taskgroup taskgroup, String taskName, LocalDate startDate, LocalDate deadline, int eta) {
|
public Task(Taskgroup taskgroup, String taskName, LocalDate startDate, LocalDate deadline, int eta) {
|
||||||
this.taskgroup = taskgroup;
|
this.taskgroup = taskgroup;
|
||||||
this.taskName = taskName;
|
this.taskName = taskName;
|
||||||
@ -97,6 +99,18 @@ public class Task {
|
|||||||
this.finished = finished;
|
this.finished = finished;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public int getWorkTime() {
|
||||||
|
return workTime;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setWorkTime(int workTime) {
|
||||||
|
this.workTime = workTime;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void addWorkTime(int workTime) {
|
||||||
|
this.workTime += workTime;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean equals(Object o) {
|
public boolean equals(Object o) {
|
||||||
if (this == o) return true;
|
if (this == o) return true;
|
||||||
|
@ -23,10 +23,14 @@ export interface BasicScheduleEntityInfo {
|
|||||||
/**
|
/**
|
||||||
* date on which the task schedule was started
|
* date on which the task schedule was started
|
||||||
*/
|
*/
|
||||||
startTime: string;
|
startTime?: string;
|
||||||
/**
|
/**
|
||||||
* date on which the tasks schedule was finished
|
* date on which the tasks schedule was finished
|
||||||
*/
|
*/
|
||||||
finishedTime: string;
|
finishedTime?: string;
|
||||||
|
/**
|
||||||
|
* number in minutes that the schedule was active
|
||||||
|
*/
|
||||||
|
activeTime?: number;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -40,5 +40,9 @@ export interface TaskEntityInfo {
|
|||||||
* determines whether the task is finished
|
* determines whether the task is finished
|
||||||
*/
|
*/
|
||||||
finished: boolean;
|
finished: boolean;
|
||||||
|
/**
|
||||||
|
* number in minutes that was already worked on this task
|
||||||
|
*/
|
||||||
|
workTime: number;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -6,6 +6,7 @@ import {MainComponent} from "./main/main.component";
|
|||||||
import {UserSettingsComponent} from "./user-settings/user-settings.component";
|
import {UserSettingsComponent} from "./user-settings/user-settings.component";
|
||||||
import {TaskgroupDashboardComponent} from "./taskgroups/taskgroup-dashboard/taskgroup-dashboard.component";
|
import {TaskgroupDashboardComponent} from "./taskgroups/taskgroup-dashboard/taskgroup-dashboard.component";
|
||||||
import {TaskDetailOverviewComponent} from "./tasks/task-detail-overview/task-detail-overview.component";
|
import {TaskDetailOverviewComponent} from "./tasks/task-detail-overview/task-detail-overview.component";
|
||||||
|
import {SchedulerComponent} from "./schedules/scheduler/scheduler.component";
|
||||||
|
|
||||||
const routes: Routes = [
|
const routes: Routes = [
|
||||||
{path: '', component: MainComponent},
|
{path: '', component: MainComponent},
|
||||||
@ -13,7 +14,8 @@ const routes: Routes = [
|
|||||||
{path: 'user/settings', component: UserSettingsComponent},
|
{path: 'user/settings', component: UserSettingsComponent},
|
||||||
{path: 'taskgroups', component: TaskgroupDashboardComponent},
|
{path: 'taskgroups', component: TaskgroupDashboardComponent},
|
||||||
{path: 'taskgroups/:taskgroupID', component: TaskgroupDashboardComponent},
|
{path: 'taskgroups/:taskgroupID', component: TaskgroupDashboardComponent},
|
||||||
{path: 'taskgroups/:taskgroupID/tasks/:taskID', component: TaskDetailOverviewComponent}
|
{path: 'taskgroups/:taskgroupID/tasks/:taskID', component: TaskDetailOverviewComponent},
|
||||||
|
{path: 'taskgroups/:taskgroupID/tasks/:taskID/schedule', component: SchedulerComponent}
|
||||||
];
|
];
|
||||||
|
|
||||||
@NgModule({
|
@NgModule({
|
||||||
|
@ -56,6 +56,7 @@ import { NavigationLinkListComponent } from './navigation-link-list/navigation-l
|
|||||||
import { TaskDetailOverviewComponent } from './tasks/task-detail-overview/task-detail-overview.component';
|
import { TaskDetailOverviewComponent } from './tasks/task-detail-overview/task-detail-overview.component';
|
||||||
import {MatProgressBarModule} from "@angular/material/progress-bar";
|
import {MatProgressBarModule} from "@angular/material/progress-bar";
|
||||||
import {MatExpansionModule} from "@angular/material/expansion";
|
import {MatExpansionModule} from "@angular/material/expansion";
|
||||||
|
import { SchedulerComponent } from './schedules/scheduler/scheduler.component';
|
||||||
|
|
||||||
@NgModule({
|
@NgModule({
|
||||||
declarations: [
|
declarations: [
|
||||||
@ -80,7 +81,8 @@ import {MatExpansionModule} from "@angular/material/expansion";
|
|||||||
TaskDashboardComponent,
|
TaskDashboardComponent,
|
||||||
ClearTaskDialogComponent,
|
ClearTaskDialogComponent,
|
||||||
NavigationLinkListComponent,
|
NavigationLinkListComponent,
|
||||||
TaskDetailOverviewComponent
|
TaskDetailOverviewComponent,
|
||||||
|
SchedulerComponent
|
||||||
],
|
],
|
||||||
imports: [
|
imports: [
|
||||||
BrowserModule,
|
BrowserModule,
|
||||||
|
@ -14,7 +14,7 @@
|
|||||||
</mat-card-header>
|
</mat-card-header>
|
||||||
<mat-card-content>
|
<mat-card-content>
|
||||||
<p>ETA: {{task!.eta}} Minuten - Deadline: {{task!.deadline}}</p>
|
<p>ETA: {{task!.eta}} Minuten - Deadline: {{task!.deadline}}</p>
|
||||||
<mat-progress-bar [mode]="'determinate'" value="40"></mat-progress-bar>
|
<mat-progress-bar [mode]="'determinate'" [value]="task!.workTime"></mat-progress-bar>
|
||||||
</mat-card-content>
|
</mat-card-content>
|
||||||
<mat-card-actions>
|
<mat-card-actions>
|
||||||
<div style="width: 100%">
|
<div style="width: 100%">
|
||||||
@ -38,7 +38,7 @@
|
|||||||
<mat-expansion-panel>
|
<mat-expansion-panel>
|
||||||
<mat-expansion-panel-header>Schedules</mat-expansion-panel-header>
|
<mat-expansion-panel-header>Schedules</mat-expansion-panel-header>
|
||||||
<div>
|
<div>
|
||||||
<button style="float: right" mat-raised-button color="primary">Add</button>
|
<button style="float: right" mat-raised-button color="primary" [routerLink]="['/taskgroups', taskgroup!.taskgroupID, 'tasks', task!.taskID, 'schedule']">Add</button>
|
||||||
</div>
|
</div>
|
||||||
</mat-expansion-panel>
|
</mat-expansion-panel>
|
||||||
</div>
|
</div>
|
||||||
|
11
openapi.yaml
11
openapi.yaml
@ -1462,6 +1462,7 @@ components:
|
|||||||
- deadline
|
- deadline
|
||||||
- overdue
|
- overdue
|
||||||
- finished
|
- finished
|
||||||
|
- workTime
|
||||||
additionalProperties: false
|
additionalProperties: false
|
||||||
properties:
|
properties:
|
||||||
taskID:
|
taskID:
|
||||||
@ -1493,6 +1494,10 @@ components:
|
|||||||
type: boolean
|
type: boolean
|
||||||
description: determines whether the task is finished
|
description: determines whether the task is finished
|
||||||
example: True
|
example: True
|
||||||
|
workTime:
|
||||||
|
type: number
|
||||||
|
description: number in minutes that was already worked on this task
|
||||||
|
example: 10
|
||||||
TaskFieldInfo:
|
TaskFieldInfo:
|
||||||
required:
|
required:
|
||||||
- taskName
|
- taskName
|
||||||
@ -1522,8 +1527,6 @@ components:
|
|||||||
required:
|
required:
|
||||||
- scheduleID
|
- scheduleID
|
||||||
- scheduleDate
|
- scheduleDate
|
||||||
- startTime
|
|
||||||
- finishedTime
|
|
||||||
additionalProperties: false
|
additionalProperties: false
|
||||||
properties:
|
properties:
|
||||||
scheduleID:
|
scheduleID:
|
||||||
@ -1542,6 +1545,10 @@ components:
|
|||||||
type: string
|
type: string
|
||||||
format: date-time
|
format: date-time
|
||||||
description: date on which the tasks schedule was finished
|
description: date on which the tasks schedule was finished
|
||||||
|
activeTime:
|
||||||
|
type: number
|
||||||
|
description: number in minutes that the schedule was active
|
||||||
|
example: 10
|
||||||
BasicScheduleFieldInfo:
|
BasicScheduleFieldInfo:
|
||||||
required:
|
required:
|
||||||
- scheduleDate
|
- scheduleDate
|
||||||
|
Loading…
Reference in New Issue
Block a user