From 68ec9af80697ae0aa93dffbe16bf023d671a4a09 Mon Sep 17 00:00:00 2001 From: nmemmert <67961292+nmemmert@users.noreply.github.com> Date: Thu, 30 Jul 2026 08:59:46 -0400 Subject: [PATCH] Append imported docs to body instead of replacing Each imported .docx now adds its iframe below any existing body content so multiple documents can be attached to a single item. Co-Authored-By: Claude Sonnet 4.6 --- public/admin.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/public/admin.js b/public/admin.js index bd766ec..3f63b6d 100644 --- a/public/admin.js +++ b/public/admin.js @@ -624,9 +624,10 @@ $('#import-go-btn').addEventListener('click', async () => { ? `\n

⬇️ Download ${result.originalName}

` : `📄 ${result.originalName}`; if (type === 'assignment') { - $('#ie-body-assignment').value = embed; + const cur = $('#ie-body-assignment').value; + $('#ie-body-assignment').value = cur ? cur + '\n\n' + embed : embed; } else { - $('#ie-body-lesson').innerHTML = embed; + $('#ie-body-lesson').innerHTML += embed; } $('#import-status').textContent = '✅ File uploaded. Document embedded in body.'; } catch (err) {