const { Router } = require('express')
const router = Router()
const userController = require('../controllers/userController')
const userAuthGPS = require('../controllers/GPS.Auth')
const userGPS = require('../controllers/GPS.User')
/// //////////////////GPS section
router.post('/gps/register', userGPS.register_user)

router.post('/gps/login/pass', userAuthGPS.login_with_pass)
router.post('/gps/login/otp', userAuthGPS.login_with_otp)

router.post('/gps/otp/send', userGPS.send_otp)
router.post('/gps/otp/check', userGPS.check_otp)

router.post('/gps/otp/reset-pass', userGPS.resetpass_otp)

/// ////////////////////////
router.post('/register/user', userController.register_user)
router.post('/reset-pass-token', userController.generate_reset_user_password_link)
router.post('/set-new-pass', userController.reset_password_using_token)

router.post('/login', userController.webLogin)
router.post('/logout', userController.webLogout)
router.get('/user', userController.getUser)



module.exports = router
