const express = require('express');
const router = express.Router();
const itemController = require('../controllers/itemController');

// router.post('/', itemController.createItem);
// router.get('/', itemController.getItems);
// router.get('/:id', itemController.getItem);
// router.put('/:id', itemController.updateItem);

// Get a single item with size-wise quantities
router.get('/:id', itemController.getItem);
router.get('/', itemController.getAllItems);

// Create a new item with sizes
router.post('/', itemController.createItem);

// Update an item with new size-wise quantities
router.put('/:id', itemController.updateItem);

// Optional: Get all items with total quantities only (without sizes)
// router.get('/', itemController.getAllItems); // <-- Implement if needed

// router.delete('/:id/permanent', itemController.deleteItem);
// router.delete('/:id', itemController.softDeleteItem);
// router.patch('/:id/restore', itemController.restoreItem);
// router.post('/bulk-upload', itemController.bulkUploadItems);

// router.get('/export/pdf', itemController.exportItemsPdf); // or similar
// router.get('/export/excel', itemController.exportItemsExcel);
// router.get('/export/print', itemController.exportItemsPrint);

module.exports = router;
