2021-12-30 00:08:41 +01:00
|
|
|
import exprs from 'express';
|
|
|
|
const { Router } = exprs;
|
|
|
|
import { isAuthenticated } from '../../utils/authCheck.js';
|
2024-06-10 21:40:37 +02:00
|
|
|
import { updateNodeSettings, getConfig, getFile, updateSelectedNode, updateApplicationSettings, getCurrencyRates, getApplicationSettings,
|
|
|
|
getExplorerFeesRecommended, getExplorerTransaction } from '../../controllers/shared/RTLConf.js';
|
2021-12-30 00:08:41 +01:00
|
|
|
|
|
|
|
const router = Router();
|
|
|
|
|
2024-06-10 21:40:37 +02:00
|
|
|
router.get('/', getApplicationSettings);
|
|
|
|
router.get('/rates', getCurrencyRates);
|
2021-12-30 00:08:41 +01:00
|
|
|
router.get('/file', isAuthenticated, getFile);
|
2022-08-07 23:12:47 +02:00
|
|
|
router.get('/updateSelNode/:currNodeIndex/:prevNodeIndex', updateSelectedNode);
|
2024-06-10 21:40:37 +02:00
|
|
|
router.get('/config/:nodeType', isAuthenticated, getConfig);
|
|
|
|
router.post('/node', isAuthenticated, updateNodeSettings);
|
|
|
|
router.post('/application', isAuthenticated, updateApplicationSettings);
|
|
|
|
router.get('/explorerFeesRecommended', getExplorerFeesRecommended);
|
|
|
|
router.get('/explorerTransaction/:txid', getExplorerTransaction);
|
2021-12-30 00:08:41 +01:00
|
|
|
|
|
|
|
export default router;
|