diff options
author | Hugo Hörnquist <hugo@lysator.liu.se> | 2020-10-05 01:44:42 +0200 |
---|---|---|
committer | Hugo Hörnquist <hugo@lysator.liu.se> | 2020-10-05 01:44:42 +0200 |
commit | c8a09ca13b97eddc5034f3e0454207d700f0105b (patch) | |
tree | a19739700b89264e147e35306245c3bc48e0d33b | |
parent | $ needed for backtick strings. (diff) | |
download | calp-c8a09ca13b97eddc5034f3e0454207d700f0105b.tar.gz calp-c8a09ca13b97eddc5034f3e0454207d700f0105b.tar.xz |
Edit tab submit now bound.
Diffstat (limited to '')
-rw-r--r-- | static/script.js | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/static/script.js b/static/script.js index 1a893e56..32e19cc4 100644 --- a/static/script.js +++ b/static/script.js @@ -575,6 +575,14 @@ window.onload = function () { */ el.parentElement.removeAttribute("href"); + /* TODO this doesn't yet apply to newly created events */ + let popup = document.getElementById("popup" + el.id); + let form = popup.getElementsByClassName("edit-form")[0]; + form.onsubmit = function () { + create_event(el); + return false; /* stop default */ + } + /* Bind all vcomponent properties into javascript. */ if (el.closest(".longevents")) { bind_properties(el, true); |