feat: Reorganize overdue projects section for improved visibility in project calendar
This commit is contained in:
@@ -265,45 +265,6 @@ export default function ProjectCalendarPage() {
|
|||||||
|
|
||||||
return (
|
return (
|
||||||
<div className="space-y-6">
|
<div className="space-y-6">
|
||||||
{/* Overdue Projects */}
|
|
||||||
{overdueProjects.length > 0 && (
|
|
||||||
<Card>
|
|
||||||
<CardHeader>
|
|
||||||
<h3 className="text-lg font-semibold text-red-600">
|
|
||||||
Projekty przeterminowane ({overdueProjects.length})
|
|
||||||
</h3>
|
|
||||||
</CardHeader>
|
|
||||||
<CardContent>
|
|
||||||
<div className="space-y-3">
|
|
||||||
{overdueProjects.map(project => (
|
|
||||||
<div key={project.project_id} className="flex items-center justify-between p-3 bg-red-50 rounded-lg border border-red-200">
|
|
||||||
<div className="flex-1">
|
|
||||||
<Link
|
|
||||||
href={`/projects/${project.project_id}`}
|
|
||||||
className="font-medium text-gray-900 hover:text-blue-600"
|
|
||||||
>
|
|
||||||
{project.project_name}
|
|
||||||
</Link>
|
|
||||||
<div className="text-sm text-gray-600 mt-1">
|
|
||||||
{project.customer && `${project.customer} • `}
|
|
||||||
{project.address}
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div className="text-right">
|
|
||||||
<div className="text-sm font-medium text-red-600">
|
|
||||||
{formatDate(project.finish_date)}
|
|
||||||
</div>
|
|
||||||
<Badge className={statusColors[project.project_status] || statusColors.registered}>
|
|
||||||
{getStatusTranslation(project.project_status) || project.project_status}
|
|
||||||
</Badge>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
))}
|
|
||||||
</div>
|
|
||||||
</CardContent>
|
|
||||||
</Card>
|
|
||||||
)}
|
|
||||||
|
|
||||||
{/* Upcoming Projects */}
|
{/* Upcoming Projects */}
|
||||||
<Card>
|
<Card>
|
||||||
<CardHeader>
|
<CardHeader>
|
||||||
@@ -353,6 +314,45 @@ export default function ProjectCalendarPage() {
|
|||||||
)}
|
)}
|
||||||
</CardContent>
|
</CardContent>
|
||||||
</Card>
|
</Card>
|
||||||
|
|
||||||
|
{/* Overdue Projects */}
|
||||||
|
{overdueProjects.length > 0 && (
|
||||||
|
<Card>
|
||||||
|
<CardHeader>
|
||||||
|
<h3 className="text-lg font-semibold text-red-600">
|
||||||
|
Projekty przeterminowane ({overdueProjects.length})
|
||||||
|
</h3>
|
||||||
|
</CardHeader>
|
||||||
|
<CardContent>
|
||||||
|
<div className="space-y-3">
|
||||||
|
{overdueProjects.map(project => (
|
||||||
|
<div key={project.project_id} className="flex items-center justify-between p-3 bg-red-50 rounded-lg border border-red-200">
|
||||||
|
<div className="flex-1">
|
||||||
|
<Link
|
||||||
|
href={`/projects/${project.project_id}`}
|
||||||
|
className="font-medium text-gray-900 hover:text-blue-600"
|
||||||
|
>
|
||||||
|
{project.project_name}
|
||||||
|
</Link>
|
||||||
|
<div className="text-sm text-gray-600 mt-1">
|
||||||
|
{project.customer && `${project.customer} • `}
|
||||||
|
{project.address}
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div className="text-right">
|
||||||
|
<div className="text-sm font-medium text-red-600">
|
||||||
|
{formatDate(project.finish_date)}
|
||||||
|
</div>
|
||||||
|
<Badge className={statusColors[project.project_status] || statusColors.registered}>
|
||||||
|
{getStatusTranslation(project.project_status) || project.project_status}
|
||||||
|
</Badge>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
))}
|
||||||
|
</div>
|
||||||
|
</CardContent>
|
||||||
|
</Card>
|
||||||
|
)}
|
||||||
</div>
|
</div>
|
||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user