Improve task management by adding project restart functionality and filtering closed projects
Enhances the task management app by introducing a "restart project" feature with options to clear history or reset tasks, refining calendar and Kanban views to use a Monday start, and enabling filtering for closed projects. Replit-Commit-Author: Agent Replit-Commit-Session-Id: ceced2fc-aa46-458d-ba87-ddd4b7bb1518 Replit-Commit-Checkpoint-Type: full_checkpoint Replit-Commit-Screenshot-Url: https://storage.googleapis.com/screenshot-production-us-central1/659922a9-0087-461c-90dd-6d9a58b81d4d/ceced2fc-aa46-458d-ba87-ddd4b7bb1518/RVJYTwu
This commit is contained in:
+17
-38
@@ -29,6 +29,7 @@ const initialTasks: Task[] = [
|
||||
timeTracked: 0,
|
||||
isTracking: false,
|
||||
projectId: 'project-1',
|
||||
notes: null,
|
||||
labelId: '2e8c3aa0-278f-4220-b2c5-aa109b4279b7' // Urgent label
|
||||
},
|
||||
{
|
||||
@@ -41,16 +42,20 @@ const initialTasks: Task[] = [
|
||||
timeTracked: 120,
|
||||
isTracking: true,
|
||||
projectId: 'project-2',
|
||||
notes: null,
|
||||
labelId: 'cb44bed1-8ba3-43fe-9498-bb28e483ed1f' // Work label
|
||||
},
|
||||
{
|
||||
id: '3',
|
||||
title: 'Team standup meeting',
|
||||
description: null,
|
||||
status: 'todo',
|
||||
priority: 'low',
|
||||
dueDate: undefined, // Make unscheduled
|
||||
dueDate: null,
|
||||
timeTracked: 0,
|
||||
isTracking: false,
|
||||
projectId: null,
|
||||
notes: null,
|
||||
labelId: '274f0ba4-a133-471a-bbe9-8189aa3b0106' // Personal label
|
||||
},
|
||||
{
|
||||
@@ -59,21 +64,25 @@ const initialTasks: Task[] = [
|
||||
description: 'Users unable to login with special characters in password',
|
||||
status: 'todo',
|
||||
priority: 'high',
|
||||
dueDate: undefined, // Make unscheduled
|
||||
dueDate: null,
|
||||
timeTracked: 30,
|
||||
isTracking: false,
|
||||
projectId: 'project-2',
|
||||
notes: null,
|
||||
labelId: 'c5eccac9-7919-4eb1-bb50-badacad6b1c1' // Study label
|
||||
},
|
||||
{
|
||||
id: '5',
|
||||
title: 'Deploy new features',
|
||||
description: null,
|
||||
status: 'done',
|
||||
priority: 'medium',
|
||||
dueDate: subDays(new Date(), 2),
|
||||
timeTracked: 120,
|
||||
isTracking: false,
|
||||
projectId: 'project-1'
|
||||
projectId: 'project-1',
|
||||
notes: null,
|
||||
labelId: null
|
||||
}
|
||||
];
|
||||
|
||||
@@ -86,14 +95,15 @@ function App() {
|
||||
const task: Task = {
|
||||
id: Date.now().toString(),
|
||||
title: newTask.title || '',
|
||||
description: newTask.description,
|
||||
description: newTask.description || null,
|
||||
status: 'todo',
|
||||
priority: newTask.priority || 'medium',
|
||||
dueDate: newTask.dueDate,
|
||||
dueDate: newTask.dueDate || null,
|
||||
timeTracked: 0,
|
||||
isTracking: false,
|
||||
projectId: newTask.projectId,
|
||||
labelId: newTask.labelId
|
||||
projectId: newTask.projectId || null,
|
||||
notes: newTask.notes || null,
|
||||
labelId: newTask.labelId || null
|
||||
};
|
||||
setTasks(prev => [...prev, task]);
|
||||
console.log('Task created:', task);
|
||||
@@ -155,37 +165,6 @@ function App() {
|
||||
/>
|
||||
);
|
||||
|
||||
case 'settings':
|
||||
return (
|
||||
<div className="space-y-6">
|
||||
<div className="space-y-4">
|
||||
<h2 className="text-lg font-semibold">Settings</h2>
|
||||
|
||||
<Card className="p-4">
|
||||
<div className="flex items-center justify-between">
|
||||
<div>
|
||||
<h3 className="font-semibold">Dark Mode</h3>
|
||||
<p className="text-sm text-muted-foreground">Toggle between light and dark themes</p>
|
||||
</div>
|
||||
<ThemeToggle />
|
||||
</div>
|
||||
</Card>
|
||||
|
||||
<Card className="p-4">
|
||||
<div className="space-y-3">
|
||||
<h3 className="font-semibold">About TaskFlow</h3>
|
||||
<p className="text-sm text-muted-foreground">
|
||||
A personal task management app with calendar scheduling, kanban boards, and project templates.
|
||||
</p>
|
||||
<div className="text-xs text-muted-foreground">
|
||||
Version 1.0.0 • Built with React and Tailwind CSS
|
||||
</div>
|
||||
</div>
|
||||
</Card>
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
|
||||
default:
|
||||
return (
|
||||
<div className="text-center py-8">
|
||||
|
||||
Reference in New Issue
Block a user