Some front JS fix
This commit is contained in:
parent
405690094f
commit
372c788396
4 changed files with 7 additions and 2 deletions
|
@ -4,7 +4,7 @@ const day = document.getElementById("day");
|
|||
const locals = {
|
||||
sandwich: document.querySelector("#oderCreator label").innerHTML,
|
||||
day: document.querySelector("label[for=day]").innerText,
|
||||
give: document.querySelector("p label span").innerText
|
||||
give: document.getElementById("dummy").innerText
|
||||
};
|
||||
|
||||
function lastOrderId() {
|
||||
|
@ -39,6 +39,8 @@ document.getElementById("addOrder").addEventListener("click", () => {
|
|||
<a class="btn-floating btn-large waves-effect waves-light red"><i class="material-icons">remove</i></a>
|
||||
</div>`);
|
||||
|
||||
M.updateTextFields();
|
||||
|
||||
sandwich.selectedIndex = 0;
|
||||
day.value = "";
|
||||
|
||||
|
|
|
@ -30,6 +30,8 @@ document.getElementById("addOrder").addEventListener("click", () => {
|
|||
<a class="btn-floating btn-large waves-effect waves-light red"><i class="material-icons">remove</i></a>
|
||||
</div>`);
|
||||
|
||||
M.updateTextFields();
|
||||
|
||||
sandwich.selectedIndex = 0;
|
||||
day.value = "";
|
||||
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
document.addEventListener("DOMContentLoaded", function() {
|
||||
M.AutoInit();
|
||||
M.updateTextFields;
|
||||
M.updateTextFields();
|
||||
});
|
||||
|
||||
function cb(token) {
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
extends ../../layout
|
||||
|
||||
block content
|
||||
span#dummy.hide=__("admin.given")
|
||||
div.container
|
||||
h1=__("admin.ordersManagement")
|
||||
div.row
|
||||
|
|
Reference in a new issue