floranet/api/controller/Delivery/delivery.controller.js

14 lines
307 B
JavaScript
Raw Normal View History

2024-03-06 17:16:03 +00:00
const db = require("../../db/db");
class DeliveryController {
async findByPostalCode(req, res) {
const { postalCode } = req.query;
const dates = await db.deliveryDate_get(postalCode);
return res.status(200).send({
data: dates[0]
})
}
}
module.exports = new DeliveryController();