feat: route to get notified of machine cashbox removal
This commit is contained in:
parent
7f35d34128
commit
8bce807220
2 changed files with 17 additions and 0 deletions
15
lib/routes/cashboxRoutes.js
Normal file
15
lib/routes/cashboxRoutes.js
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
const express = require('express')
|
||||
const router = express.Router()
|
||||
|
||||
function notifyCashboxRemoval (req, res, next) {
|
||||
Promise.resolve()
|
||||
.then(() => {
|
||||
console.log(`Device ${req.deviceId} had its cashbox removed.`)
|
||||
return res.status(200).send({ status: 'OK' })
|
||||
})
|
||||
.catch(next)
|
||||
}
|
||||
|
||||
router.post('/cashboxremoval', notifyCashboxRemoval)
|
||||
|
||||
module.exports = router
|
||||
Loading…
Add table
Add a link
Reference in a new issue