From f2b289f1f48c631648abe0a3ce5461372d0d42e4 Mon Sep 17 00:00:00 2001 From: Matias De lellis Date: Tue, 16 Jun 2020 12:07:58 -0300 Subject: [PATCH] Fix read only notes. --- js/script.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/js/script.js b/js/script.js index 06dcdf2..ef3f603 100644 --- a/js/script.js +++ b/js/script.js @@ -148,10 +148,9 @@ Notes.prototype = { var self = this; $.get(OC.linkToOCS('apps/files_sharing/api/v1/', 1) + 'sharees', { format: 'json', - itemType: 'principals' + itemType: '1' }).done(function (shares) { var users = []; - console.log(shares); $.each(shares.ocs.data.exact.users, function(index, user) { users.push(user.value.shareWith); }); @@ -708,15 +707,16 @@ View.prototype = { return $('#title-editable').prop('contenteditable'); else { if (editable) { - $('#title-editable').prop('contenteditable', true); $('#modal-note-div .icon-header-note').show(); + $('#title-editable').prop('contenteditable', true); $('#modal-note-div .note-options').show(); $('#modal-note-div .note-disable-options').hide(); this._initEditor(); } else { - $('#modal-note-div .note-options').hide(); $('#modal-note-div .icon-header-note').hide(); $('#title-editable').removeAttr("contentEditable"); + $('#content-editable').removeAttr("contentEditable"); + $('#modal-note-div .note-options').hide(); $('#modal-note-div .note-disable-options').show(); } }