Browse Source

Small bug fixes to Modal.

dev
Bryan Miller 5 years ago
parent
commit
ad3a1a9ecd
1 changed files with 1 additions and 3 deletions
  1. +1
    -3
      app/js/ui/Modal.js

+ 1
- 3
app/js/ui/Modal.js View File

}).bind(this)); }).bind(this));


GlobalEvents.listen("modal-submit", (function(target, event){ GlobalEvents.listen("modal-submit", (function(target, event){
if (target !== this.__currentModalEl)
return;
if (!event.hasOwnProperty("subevent")) if (!event.hasOwnProperty("subevent"))
return; return;
var ename = event.subevent; var ename = event.subevent;
ids.forEach((item) => { ids.forEach((item) => {
var id = item.trim(); var id = item.trim();
var el = cel.querySelector("[name='" + id + "']"); var el = cel.querySelector("[name='" + id + "']");
if (el && el.hasOwnProperty("value"))
if (el) // TODO: Check if el is an INPUT node and switch between the node types.
vals[id] = el.value; vals[id] = el.value;
}); });
} }

Loading…
Cancel
Save