Added Menu List and the Menu Table view.

This commit is contained in:
Brian McGonagill 2022-08-26 17:10:05 -05:00
parent 25ce44d9cf
commit 3290b3086a
16 changed files with 401 additions and 0 deletions

View file

@ -6,6 +6,8 @@ import { Categories } from '../imports/api/category.js';
import { Locations } from '../imports/api/location.js';
import { Lists } from '../imports/api/lists.js';
import { ListItems } from '../imports/api/listItems.js';
import { Menus } from '../imports/api/menu.js';
import { MenuItems } from '../imports/api/menuItems.js';
Meteor.publish("SystemConfig", function() {
try {
@ -66,4 +68,20 @@ Meteor.publish("myListItems", function(listId) {
} catch (error) {
console.log(" ERROR pulling list items for this list: " + error);
}
});
Meteor.publish("myMenus", function() {
try {
return Menus.find({ menuComplete: false });
} catch (error) {
console.log(" ERROR pulling menu info: " + error);
}
});
Meteor.publish("myMenuItems", function(menuId) {
try {
return MenuItems.find({ menuId: menuId });
} catch (error) {
console.log(" ERROR pulling list items for this list: " + error);
}
});