Editor - Business menu settings

This view is a fashion that opens when the function showBusinessMenuSttings() is used in the view theme/views/editor/business-menu.html and it serves to add or modify the menus of a business.

Main Models

  • menu.name: menus name
  • menu.delivery: Boolean, check if the menu is of the delivery type.
  • menu.pickup: boolean, check if the menu is pick-up type.
  • menu.comment: string, comentario acerca del menu
  • categories: contains the categories of the business.
  • curCategory: aux for select one category

Utility Functions

  • hideBusinessMenuSettings(): It serves to close this view
  • updateMenu(menu, categories): update menu information
  • addMenu(menu, categories): add a new menu
  • editSchedule(): Open a modal that is used to manage schedules
  • toggleCategory(category_id): It serves to change
  • toggleAll(category): Check / uncheck all the products of a category for the menu
  • toggleProduct(category): check / uncheck a product for the menu

Example of base theme

426
  1. Menus basic information
  2. categories and products selection for menu.