const express = require('express');
const router = express.Router();
const { requireAuth } = require('../middleware/auth');
const ctrl = require('../controllers/partnerController');

router.use(requireAuth);

// Read-only: CRUD는 tkuser로 이관됨
router.get('/search', ctrl.searchCompanies);
router.get('/', ctrl.list);
router.get('/:id', ctrl.getById);
router.get('/:id/workers', ctrl.listWorkers);

module.exports = router;
