feat: complete Phase 4 of service refactoring

- Marked tasks in `TODO.md` as completed for moving task-related files to the `task-management` directory and correcting imports across the codebase.
- Updated imports in `seed-data.ts`, `seed-tags.ts`, API routes, and various components to reflect the new structure.
- Removed obsolete `daily.ts`, `tags.ts`, and `tasks.ts` files to streamline the codebase.
- Added new tasks in `TODO.md` for future cleaning and organization of service imports.
This commit is contained in:
Julien Froidefond
2025-09-23 10:25:41 +02:00
parent b8e0307f03
commit f5417040fd
23 changed files with 38 additions and 35 deletions

View File

@@ -1,5 +1,5 @@
import { NextRequest, NextResponse } from 'next/server';
import { dailyService } from '@/services/daily';
import { dailyService } from '@/services/task-management/daily';
export async function PATCH(
request: NextRequest,

View File

@@ -1,5 +1,5 @@
import { NextResponse } from 'next/server';
import { dailyService } from '@/services/daily';
import { dailyService } from '@/services/task-management/daily';
/**
* API route pour récupérer toutes les dates avec des dailies

View File

@@ -1,5 +1,5 @@
import { NextRequest, NextResponse } from 'next/server';
import { dailyService } from '@/services/daily';
import { dailyService } from '@/services/task-management/daily';
import { DailyCheckboxType } from '@/lib/types';
export async function GET(request: NextRequest) {

View File

@@ -1,5 +1,5 @@
import { NextResponse } from 'next/server';
import { dailyService } from '@/services/daily';
import { dailyService } from '@/services/task-management/daily';
import { getToday, parseDate, isValidAPIDate, createDateFromParts } from '@/lib/date-utils';
/**

View File

@@ -1,5 +1,5 @@
import { NextRequest, NextResponse } from 'next/server';
import { tagsService } from '@/services/tags';
import { tagsService } from '@/services/task-management/tags';
/**
* GET /api/tags/[id] - Récupère un tag par son ID

View File

@@ -1,5 +1,5 @@
import { NextRequest, NextResponse } from 'next/server';
import { tagsService } from '@/services/tags';
import { tagsService } from '@/services/task-management/tags';
/**
* GET /api/tags - Récupère tous les tags ou recherche par query

View File

@@ -1,5 +1,5 @@
import { NextRequest, NextResponse } from 'next/server';
import { tasksService } from '@/services/tasks';
import { tasksService } from '@/services/task-management/tasks';
export async function GET(
request: NextRequest,

View File

@@ -1,5 +1,5 @@
import { NextResponse } from 'next/server';
import { tasksService } from '@/services/tasks';
import { tasksService } from '@/services/task-management/tasks';
import { TaskStatus } from '@/lib/types';
/**