widget leantime refactor

This commit is contained in:
alma 2026-01-15 23:29:48 +01:00
parent 35fe260914
commit 7a47b89114

View File

@ -209,7 +209,7 @@ export function Duties() {
type: t.type || 'main',
source: (t as any).source || 'leantime'
})));
setTasks(sortedTasks.slice(0, 7));
setTasks(sortedTasks);
} catch (error) {
console.error('Error fetching tasks:', error);
setError(error instanceof Error ? error.message : 'Failed to fetch tasks');
@ -343,7 +343,10 @@ export function Duties() {
<div className="flex items-center text-gray-500 text-[10px] bg-gray-50 px-1.5 py-0.5 rounded-md">
<Folder className="h-2.5 w-2.5 mr-1 opacity-70" />
{(task as any).source === 'twenty-crm' ? (
<span className="text-[9px] text-purple-600 font-medium">SLM IF (Médiation)</span>
<>
<span className="truncate">SLM IF</span>
<span className="ml-1 text-[9px] text-purple-600 font-medium">(Médiation)</span>
</>
) : (
<>
<span className="truncate">{task.projectName}</span>