Gitlab@Informatics

Skip to content
Snippets Groups Projects
Commit feb800ac authored by 65160270's avatar 65160270
Browse files

update-images

parent 192ca16b
No related branches found
No related tags found
No related merge requests found
......@@ -46,9 +46,6 @@ router.post("/add", upload.single("image"), async (req, res) => { // เปล
try {
const { name, price, stock, description } = req.body; // เพิ่ม description
if (!name || !price || !stock || !description || !req.file) {
return res.status(400).send("กรุณากรอกข้อมูลให้ครบถ้วน และเลือกรูปภาพ");
}
const imagePath = "/uploads/" + req.file.filename;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment