mirror of
https://github.com/zadam/trilium.git
synced 2025-11-02 03:16:11 +01:00
Merge branch 'm38'
# Conflicts: # docs/backend_api/Note.html # docs/frontend_api/NoteShort.html # src/services/import/enex.js
This commit is contained in:
@@ -53,10 +53,12 @@ async function getChildren(req) {
|
||||
}
|
||||
|
||||
async function createNote(req) {
|
||||
const parentNoteId = req.params.parentNoteId;
|
||||
const newNote = req.body;
|
||||
const params = Object.assign({}, req.body); // clone
|
||||
params.parentNoteId = req.params.parentNoteId;
|
||||
|
||||
const { note, branch } = await noteService.createNewNote(parentNoteId, newNote, req);
|
||||
const { target, targetBranchId } = req.query;
|
||||
|
||||
const { note, branch } = await noteService.createNewNoteWithTarget(target, targetBranchId, params);
|
||||
|
||||
await treeService.setCssClassesToNotes([note]);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user