let globalHistoryItems = null; function showCurrentNoteHistory() { showNoteHistoryDialog(globalCurrentNote.detail.note_id); } function showNoteHistoryDialog(noteId, noteHistoryId) { $("#note-history-dialog").dialog({ modal: true, width: 800, height: 700 }); $("#note-history-list").empty(); $("#note-history-content").empty(); $.ajax({ url: baseApiUrl + 'notes-history/' + noteId, type: 'GET', success: result => { globalHistoryItems = result; for (const row of result) { const dateModified = getDateFromTS(row.date_modified); $("#note-history-list").append($('