Make sure that time entry billable status updates when project changes,

fixes #981
This commit is contained in:
Gregor Vostrak
2026-02-04 17:07:46 +01:00
parent 531443f0df
commit 6804eb098d
5 changed files with 473 additions and 0 deletions

View File

@@ -67,10 +67,12 @@ function updateStartEndTime(start: string, end: string | null) {
}
function updateProjectAndTask(projectId: string, taskId: string) {
const project = props.projects.find((p) => p.id === projectId);
props.updateTimeEntry({
...props.timeEntry,
project_id: projectId,
task_id: taskId,
billable: project ? project.is_billable : props.timeEntry.billable,
});
}