feat: export/import ZIP — garantie_types + referentiel_notation (fichier complet)
This commit is contained in:
@@ -1071,4 +1071,13 @@ router.put('/notation/:notationId', (req, res, next) => {
|
|||||||
});
|
});
|
||||||
|
|
||||||
// DELETE /api/referentiel/notation/:notationId
|
// DELETE /api/referentiel/notation/:notationId
|
||||||
rou
|
router.delete('/notation/:notationId', (req, res, next) => {
|
||||||
|
try {
|
||||||
|
const existing = db.prepare('SELECT id FROM referentiel_notation WHERE id = ?').get(req.params.notationId);
|
||||||
|
if (!existing) throw new HttpError(404, 'Critere introuvable');
|
||||||
|
db.prepare('DELETE FROM referentiel_notation WHERE id = ?').run(req.params.notationId);
|
||||||
|
res.json({ deleted: true });
|
||||||
|
} catch (e) { next(e); }
|
||||||
|
});
|
||||||
|
|
||||||
|
export default router;
|
||||||
|
|||||||
Reference in New Issue
Block a user