From 370dd7d841966514ea7751e75afcb57f63c3966a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jon=C3=A1=C5=A1=20Havelka?= Date: Tue, 21 Jan 2025 08:12:42 +0100 Subject: [PATCH] =?UTF-8?q?U=C5=BE=20nem=C3=A1me=20text=20v=20oprav=C4=9B,?= =?UTF-8?q?=20tak=C5=BEe=20nem=C3=A1=20smysl=20ho=20editovat?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- korektury/static/korektury/opraf.js | 15 +++------------ .../korektury/korekturovatko/__oprava.html | 2 +- 2 files changed, 4 insertions(+), 13 deletions(-) diff --git a/korektury/static/korektury/opraf.js b/korektury/static/korektury/opraf.js index 78cee8d2..c7403393 100644 --- a/korektury/static/korektury/opraf.js +++ b/korektury/static/korektury/opraf.js @@ -98,23 +98,14 @@ function toggle_visibility(oprava){ } } -// show comment form, when 'edit' or 'comment' button pressed -function box_edit(op, action) +// show comment form, when 'comment' button pressed +function comment(op) { var divpointer = document.getElementById(op.id + '-pointer'); - var text; - if (action == 'update') { - var text_el = document.getElementById(op.id + '-text'); - text = text_el.textContent; - - } else { - text = ''; - } - var dx = parseInt(divpointer.style.left); var dy = parseInt(divpointer.style.top); - return show_form(op.img_id, dx, dy, op.dataset.opid, text, action); + return show_form(op.img_id, dx, dy, op.dataset.opid, "", "comment"); } // show comment form when 'update-comment' button pressed diff --git a/korektury/templates/korektury/korekturovatko/__oprava.html b/korektury/templates/korektury/korekturovatko/__oprava.html index a2a9bbce..32c6225f 100644 --- a/korektury/templates/korektury/korekturovatko/__oprava.html +++ b/korektury/templates/korektury/korekturovatko/__oprava.html @@ -49,7 +49,7 @@ -