const express = require('express');
const router = express.Router();
const productionMaterialCertificationController = require('../controllers/productionMaterialCertificationController');
const authMiddleware = require('../middleware/auth');

// 暂时注释掉认证中间件用于测试
// router.use(authMiddleware);

// 生资认证管理路由
router.get('/', productionMaterialCertificationController.getProductionMaterialCertifications);
router.get('/:id', productionMaterialCertificationController.getProductionMaterialCertificationById);
router.post('/', productionMaterialCertificationController.createProductionMaterialCertification);
router.put('/:id', productionMaterialCertificationController.updateProductionMaterialCertification);
router.delete('/:id', productionMaterialCertificationController.deleteProductionMaterialCertification);
router.patch('/:id/status', productionMaterialCertificationController.toggleCertificationStatus);

module.exports = router;
