diff options
| author | Bobby <[email protected]> | 2022-05-03 22:04:04 -0400 |
|---|---|---|
| committer | Bobby <[email protected]> | 2022-05-03 22:04:04 -0400 |
| commit | f1b9662122abed09ccf74b2eda034e7a45730e60 (patch) | |
| tree | 2e34ce476542d17871791d19fb45fd6a20d61bfa /interface/routes/api | |
| parent | 00826988bf4d1fba76c0a65fa850639844ef61a4 (diff) | |
| download | Welfare-Schemes-DMQL-f1b9662122abed09ccf74b2eda034e7a45730e60.tar.xz Welfare-Schemes-DMQL-f1b9662122abed09ccf74b2eda034e7a45730e60.zip | |
citizens pagination
Diffstat (limited to 'interface/routes/api')
| -rw-r--r-- | interface/routes/api/citizens.js | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/interface/routes/api/citizens.js b/interface/routes/api/citizens.js index fc98928..c6c6425 100644 --- a/interface/routes/api/citizens.js +++ b/interface/routes/api/citizens.js @@ -3,6 +3,12 @@ const router = express.Router(); const citizensController = require("../../controllers/citizens.controller"); +router.get('/count', (req, res) => { + citizensController.getCountOfCitizens().then(count => { + res.json({ count }); + }); +}); + router.post("/edit", (req, res) => { const { citizen_id, address, mobile_num, dob, marital_status } = req.body; if (!citizen_id || !address || !mobile_num || !dob || !marital_status) { |
