mirror of
https://gitlab.com/bmcgonag/get_my.git
synced 2026-03-27 00:08:49 +00:00
Updated Menus and Menu Items to use newer materialize
This commit is contained in:
parent
ea3ed117ff
commit
81559683eb
9 changed files with 59 additions and 54 deletions
|
|
@ -1,4 +1,5 @@
|
|||
import { Menus } from '../../imports/api/menu.js';
|
||||
import { M } from '../lib/assets/materialize.js';
|
||||
|
||||
Template.addMenuModal.onCreated(function() {
|
||||
this.subscribe("myMenus");
|
||||
|
|
@ -6,7 +7,8 @@ Template.addMenuModal.onCreated(function() {
|
|||
|
||||
Template.addMenuModal.onRendered(function() {
|
||||
Session.set("menuNameErr", false);
|
||||
$('.modal').modal();
|
||||
var elems = document.querySelectorAll('.modal');
|
||||
var instances = M.Modal.init(elems, {});
|
||||
});
|
||||
|
||||
Template.addMenuModal.helpers({
|
||||
|
|
@ -31,13 +33,8 @@ Template.addMenuModal.events({
|
|||
} else {
|
||||
console.log(" SUCCESS adding menu.");
|
||||
$("#menuNameInp").val("");
|
||||
$("#modalMenu").modal('close');
|
||||
}
|
||||
});
|
||||
}
|
||||
},
|
||||
'click .renameMenu' (event) {
|
||||
event.preventDefault();
|
||||
|
||||
},
|
||||
});
|
||||
Loading…
Add table
Add a link
Reference in a new issue