mirror of
https://github.com/zadam/trilium.git
synced 2025-11-08 14:25:51 +01:00
backend ported to node.js (work in progress)
This commit is contained in:
13
node/routes/note_history.js
Normal file
13
node/routes/note_history.js
Normal file
@@ -0,0 +1,13 @@
|
||||
const express = require('express');
|
||||
const router = express.Router();
|
||||
const sql = require('../sql');
|
||||
|
||||
router.get('/:noteId', async (req, res, next) => {
|
||||
const noteId = req.params.noteId;
|
||||
|
||||
const history = await sql.getResults("select * from notes_history where note_id = ? order by date_modified desc", [noteId]);
|
||||
|
||||
res.send(history);
|
||||
});
|
||||
|
||||
module.exports = router;
|
||||
Reference in New Issue
Block a user