@tanglemedia/directus-collection-food-menu
v0.0.1
Published
Installs the Food Menu Category and Food Item collections to your Directus project.
Downloads
98
Readme
@tanglemedia/directus-collection-food-menu
Installs the Food Menu collections to your Directus project.
The package will install the following collections:
- Food Menu Category
tngl_food_menu_category - Food Item
tngl_food_item
A Food Menu Category can have many Food Items, and a Food Item belongs to a single Food Menu Category (one-to-many / many-to-one).
Requirements
- Directus >= 10.10.1
- Node >= 18.x.x
Install
npm i @tanglemedia/directus-collection-food-menunpx directus bootstrapto update your database and restart directus
What's inside the package
Food Menu Category (tngl_food_menu_category)
- Status (defaults to "Draft")
- Title
- URL (
slug, unique) - Image (
directus_filesrelation) - Food Items (
food_items, one-to-many totngl_food_item) - Content (
tngl_flx_cntnt— Flex Editor content, requires@tanglemedia/directus-collection-flex-editor) - SEO group
- Keywords
- Description
Food Item (tngl_food_item)
- Status (defaults to "Draft")
- Title
- URL (
slug, unique) - Image (
directus_filesrelation) - Price (
decimal(10,2)) - Food Menu Category (
category, many-to-one totngl_food_menu_category) - Content (
tngl_flx_cntnt— Flex Editor content, requires@tanglemedia/directus-collection-flex-editor) - SEO group
- Keywords
- Description
In both collections, fields are ordered so the Content editor appears immediately before the SEO group.
The slug prefix is built from the
SITE_BASE_URLenvironment variable, e.g.${SITE_BASE_URL}/food-menu-category/and${SITE_BASE_URL}/food-item/.
