close note type dropdown after click

This commit is contained in:
zadam 2020-09-15 00:13:25 +02:00
parent 85d13b1d62
commit f5216e4799
3 changed files with 2 additions and 3 deletions

View File

@ -7,7 +7,6 @@ import Attribute from "../entities/attribute.js";
import options from "./options.js"; import options from "./options.js";
import treeCache from "./tree_cache.js"; import treeCache from "./tree_cache.js";
import noteAttributeCache from "./note_attribute_cache.js"; import noteAttributeCache from "./note_attribute_cache.js";
import tree from "./tree.js";
const $outstandingSyncsCount = $("#outstanding-syncs-count"); const $outstandingSyncsCount = $("#outstanding-syncs-count");

View File

@ -64,6 +64,8 @@ export default class NoteTypeWidget extends TabAwareWidget {
const noteType = NOTE_TYPES.find(nt => nt.type === type); const noteType = NOTE_TYPES.find(nt => nt.type === type);
this.save(noteType.type, noteType.mime); this.save(noteType.type, noteType.mime);
this.$widget.find('.dropdown-toggle').dropdown('toggle');
}); });
if (this.note.type === noteType.type) { if (this.note.type === noteType.type) {

View File

@ -237,8 +237,6 @@ async function findSimilarNotes(noteId) {
maxDate: dateUtils.utcDateStr(new Date(dateCreatedTs + 1800)), maxDate: dateUtils.utcDateStr(new Date(dateCreatedTs + 1800)),
}; };
console.log("ORIG:", origNote.flatText);
for (const note of Object.values(noteCache.notes)) { for (const note of Object.values(noteCache.notes)) {
if (note.noteId === origNote.noteId) { if (note.noteId === origNote.noteId) {
continue; continue;