import type { FastifyInstance } from 'fastify';
import * as reviewController from '../controllers/reviewController.js';

export default async function reviewRoutes(fastify: FastifyInstance) {
  // ==================== 稿件审查 API ====================

  // 上传稿件并开始审查
  fastify.post('/review/upload', reviewController.uploadManuscript);

  // 获取任务状态
  fastify.get('/review/tasks/:taskId', reviewController.getTaskStatus);

  // 获取审查报告
  fastify.get('/review/tasks/:taskId/report', reviewController.getTaskReport);

  // 获取任务列表
  fastify.get('/review/tasks', reviewController.getTaskList);

  // 删除任务
  fastify.delete('/review/tasks/:taskId', reviewController.deleteTask);
}





























