تنفيذ المخزون الارتباطي المتقدم

يصف كيان "القائمة" قائمة طعام يقدمها مطعم لعملائه. حاسمة يجب تحديد كيان القائمة داخل كيان "المطعم" من خلال بيان "المطعم" الموقع: menuId.

كائنات أخرى تحدد القائمة (مثل الوصف والصورة والإضافات معلومات التغذية) تشمل MenuItem وMenuItemOffer، بالإضافة إلى الكائنات الاختيارية MenuSection وAvailability وMenuItemOption.

يمكنك استخدام كائنات MenuSection لتنظيم عدة كائنات MenuItem في والفئات المنطقية. هذا النهج مفيد للمطاعم التي لديها عدة (مثل الإفطار والغداء والعشاء). أضف كل قائمة باعتبارها قائمة MenuSection

حالة الاستخدام أفضل ممارسة
حالة الاستخدام 1: القائمة الأساسية استخدام MenuItem وMenuItemOffer MenuSection (اختياري)

يتطابق المثال التالي مع "القائمة الأساسية" حالة استخدام مع قسمين للقائمة ("الطعام طوال اليوم" و"المشروبات")، يحتوي كل منهما على عنصرين من القائمة:

JSON

{
  "@type": "Menu",
  "name": "Coffee Shop A",
  "@id": "1535"
} {
  "@type": "MenuSection",
  "@id": "4371",
  "menuId": {
    "@id": "1535",
    "displayOrder": 1
  },
  "name": "All day food",
  "menuItemId": ["1", "2"]
} {
  "@type": "MenuItem",
  "@id": "1",
  "name": "Mediterranean Bagel",
  "description": "rocket, scrambled egg, tomato relish, bacon ***Gluten free bagel available***",
  "image": "https://www.gstatic.com/mobilesdk/170329_assistant/assistant_color_28dp.png",
  "parentMenuSectionId": {
    "@id": "4371",
    "displayOrder": 1
  }
} {
  "@type": "MenuItemOffer",
  "@id": "6680262",
  "sku": "offer-mediterranean-bagel",
  "menuItemId": "1",
  "price": 17.60,
  "priceCurrency": "AUD"
} {
  "@type": "MenuItem",
  "@id": "2",
  "name": "Club Empire Bagel",
  "description": "grilled chicken, bacon, rocket, tomato relish ***Gluten Free Bagels Available***",
  "image": "https://www.gstatic.com/mobilesdk/170329_assistant/assistant_color_28dp.png",
  "parentMenuSectionId": {
    "@id": "4371",
    "displayOrder": 2
  }
} {
  "@type": "MenuItemOffer",
  "@id": "428",
  "sku": "offer-club-empire-bagel",
  "menuItemId": "2",
  "price": 18.90,
  "priceCurrency": "AUD"
} {
  "@type": "MenuSection",
  "@id": "27",
  "menuId": {
    "@id": "1535",
    "displayOrder": 2
  },
  "name": "Drinks",
  "menuItemId": ["3", "4"]
} {
  "@type": "MenuItem",
  "@id": "3",
  "name": "Cold Brew Coffee",
  "description": "67% less acid & refreshingly good",
  "image": "https://www.gstatic.com/mobilesdk/170329_assistant/assistant_color_28dp.png",
  "parentMenuSectionId": {
    "@id": "27",
    "displayOrder": 1
  }
} {
  "@type": "MenuItemOffer",
  "@id": "456",
  "sku": "offer-cold-brew-coffee",
  "menuItemId": "3",
  "price": 8.50,
  "priceCurrency": "AUD"
} {
  "@type": "MenuItem",
  "@id": "4",
  "name": "English Breakfast Tea",
  "description": "Not Coffee. Try our tea",
  "image": "https://www.gstatic.com/mobilesdk/170329_assistant/assistant_color_28dp.png",
  "parentMenuSectionId": {
    "@id": "27",
    "displayOrder": 2
  }
} {
  "@type": "MenuItemOffer",
  "@id": "4432",
  "sku": "offer-english-breakfast-tea",
  "menuItemId": "4",
  "price": 5.50,
  "priceCurrency": "AUD"
}

قائمة طعام لفترة محدودة

يمكن استخدام MenuItemOffer عنصر مدمج مع Availability لإنشاء عناصر قائمة لفترة محدودة وخيارات عناصر القائمة. استخدام كائنات Availability من أجل إنشاء أقسام قائمة محدودة زمنيًا بدلاً من ذلك.

حالة الاستخدام أفضل ممارسة
حالة الاستخدام 1: قسم القائمة "فيديوهات محدودة" استخدِم Availability لتحديد سمات القسم. availabilityStarts وavailabilityEnds الوقت.
حالة الاستخدام 2: صنف في قائمة لفترة محدودة استخدِم menuItemId لـ MenuItemOffer من أجل تحديد MenuItem الذي يرتبط به العرض استخدام Availability لتحديد المزايا التي سيحصلون عليها في العرض availabilityStarts وavailabilityEnds و availabilityDaycode> الوقت.
حالة الاستخدام 3: عنصر في قائمة عروض متعدّدة استخدام السمة menuItemId الخاصة بـ MenuItemOffer وضبطها السمة availabilityId لتحديد الوقت الذي يكون السعر صالحًا.

JSON

قائمة أساسية تضم "أطعمة طوال اليوم" و"غداء" و"مشروبات" الأقسام.

تتضمن القائمة ثلاثة أقسام. "الغداء (من 11:30 صباحًا حتى 2:30 بعد الظهر)" هذا القسم متاح فقط من الساعة 11:30 صباحًا حتى الساعة 2:30 بعد الظهر كما هو موضّح في كائن Availability.

{
  "@type": "Menu",
  "name": "Coffee Shop A",
  "@id": "1535"
} {
  "@type": "MenuSection",
  "@id": "4371",
  "menuId": {
    "@id": "1535",
    "displayOrder": 1
  },
  "name": "All day food",
  "menuItemId": ["1", "2"]
} {
  "@type": "MenuItem",
  "@id": "1",
  "name": "Mediterranean Bagel",
  "description": "rocket, scrambled egg, tomato relish, bacon ***Gluten free bagel available***",
  "image": "https://www.gstatic.com/mobilesdk/170329_assistant/assistant_color_28dp.png",
  "parentMenuSectionId": {
    "@id": "4371",
    "displayOrder": 1
  }
} {
  "@type": "MenuItemOffer",
  "@id": "6680262",
  "sku": "offer-mediterranean-bagel",
  "menuItemId": "1",
  "price": 17.60,
  "priceCurrency": "AUD"
} {
  "@type": "MenuItem",
  "@id": "2",
  "name": "Club Empire Bagel",
  "description": "grilled chicken, bacon, rocket, tomato relish ***Gluten Free Bagels Available***",
  "image": "https://www.gstatic.com/mobilesdk/170329_assistant/assistant_color_28dp.png",
  "parentMenuSectionId": {
    "@id": "4371",
    "displayOrder": 2
  }
} {
  "@type": "MenuItemOffer",
  "@id": "428",
  "sku": "offer-club-empire-bagel",
  "menuItemId": "2",
  "price": 18.90,
  "priceCurrency": "AUD"
} {
  "@type": "MenuSection",
  "@id": "27",
  "menuId": {
    "@id": "1535",
    "displayOrder": 3
  },
  "name": "Drinks",
  "menuItemId": ["3", "4"]
} {
  "@type": "MenuItem",
  "@id": "3",
  "name": "Cold Brew Coffee",
  "description": "67% less acid & refreshingly good",
  "image": "https://www.gstatic.com/mobilesdk/170329_assistant/assistant_color_28dp.png",
  "parentMenuSectionId": {
    "@id": "27",
    "displayOrder": 1
  }
} {
  "@type": "MenuItemOffer",
  "@id": "3",
  "sku": "offer-cold-brew-coffee",
  "menuItemId": "3",
  "price": 8.50,
  "priceCurrency": "AUD"
} {
  "@type": "MenuItem",
  "@id": "4",
  "name": "English Breakfast Tea",
  "description": "Not Coffee. Try our tea",
  "image": "https://www.gstatic.com/mobilesdk/170329_assistant/assistant_color_28dp.png",
  "parentMenuSectionId": {
    "@id": "27",
    "displayOrder": 2
  }
} {
  "@type": "MenuItemOffer",
  "@id": "4",
  "sku": "offer-english-breakfast-tea",
  "menuItemId": "4",
  "price": 5.50,
  "priceCurrency": "AUD"
} {
  "@type": "Availability",
  "@id": "85343705",
  "availabilityStarts": "11:30",
  "availabilityEnds": "14:30"
} {
  "@type": "MenuSection",
  "@id": "53",
  "menuId": {
    "@id": "1535",
    "displayOrder": 2
  },
  "name": "Lunch (Available 11:30am - 2:30pm)",
  "menuItemId": ["5", "6"],
  "availabilityId": ["85343705"]
} {
  "@type": "MenuItem",
  "@id": "5",
  "name": "Bibimbap",
  "description": "pulled pork, julienned carrot, cucumber, spring onions, brown rice, pureed kimchi, fried free-range egg.",
  "image": "https://www.gstatic.com/mobilesdk/170329_assistant/assistant_color_28dp.png",
  "parentMenuSectionId": {
    "@id": "53",
    "displayOrder": 1
  }
} {
  "@type": "MenuItemOffer",
  "@id": "753",
  "sku": "offer-bibimbap",
  "menuItemId": "5",
  "price": 24.80,
  "priceCurrency": "AUD"
} {
  "@type": "MenuItem",
  "@id": "6",
  "name": "The Big Chicken",
  "description": "WA free range handmade chicken burger, lettuce, avocado, bacon, tomato relish on charcoal brioche bun, sweet potato wedges and house made aioli (vegetarian option – spiced lentil burger, just ask us in the notes)",
  "image": "https://www.gstatic.com/mobilesdk/170329_assistant/assistant_color_28dp.png",
  "parentMenuSectionId": {
    "@id": "53",
    "displayOrder": 2
  }
} {
  "@type": "MenuItemOffer",
  "@id": "856",
  "sku": "offer-big-chicken",
  "menuItemId": "6",
  "price": 25.60,
  "priceCurrency": "AUD"
}

JSON

قائمة أساسية تضم "أطعمة طوال اليوم" و"غداء" و"مشروبات" الأقسام.

تتضمن القائمة ثلاثة أقسام. "الغداء (من 11:30 صباحًا حتى 2:30 بعد الظهر)" هذا القسم متاح فقط من الساعة 11:30 صباحًا حتى الساعة 2:30 بعد الظهر كما هو موضّح في كائن Availability. عنصر القائمة "Bibimbap" هو فقط متاحة من الساعة 12:00 بعد الظهر إلى الساعة 1:00 بعد الظهر، كما هو موضّح من قِبل Availability المشار إليها في كائن MenuItemOffer المقابل.

{
  "@type": "Menu",
  "name": "Coffee Shop A",
  "@id": "1535"
} {
  "@type": "MenuSection",
  "@id": "4371",
  "menuId": {
    "@id": "1535",
    "displayOrder": 1
  },
  "name": "All day food",
  "menuItemId": ["1", "2"]
} {
  "@type": "MenuItem",
  "@id": "1",
  "name": "Mediterranean Bagel",
  "description": "rocket, scrambled egg, tomato relish, bacon ***Gluten free bagel available***",
  "image": "https://www.gstatic.com/mobilesdk/170329_assistant/assistant_color_28dp.png",
  "parentMenuSectionId": {
    "@id": "4371",
    "displayOrder": 1
  }
} {
  "@type": "MenuItemOffer",
  "@id": "6680262",
  "sku": "offer-mediterranean-bagel",
  "menuItemId": "1",
  "price": 17.60,
  "priceCurrency": "AUD"
} {
  "@type": "MenuItem",
  "@id": "2",
  "name": "Club Empire Bagel",
  "description": "grilled chicken, bacon, rocket, tomato relish ***Gluten Free Bagels Available***",
  "image": "https://www.gstatic.com/mobilesdk/170329_assistant/assistant_color_28dp.png",
  "parentMenuSectionId": {
    "@id": "4371",
    "displayOrder": 2
  }
} {
  "@type": "MenuItemOffer",
  "@id": "428",
  "sku": "offer-club-empire-bagel",
  "menuItemId": "2",
  "price": 18.90,
  "priceCurrency": "AUD"
} {
  "@type": "MenuSection",
  "@id": "27",
  "menuId": {
    "@id": "1535",
    "displayOrder": 3
  },
  "name": "Drinks",
  "menuItemId": ["3", "4"]
} {
  "@type": "MenuItem",
  "@id": "3",
  "name": "Cold Brew Coffee",
  "description": "67% less acid & refreshingly good",
  "image": "https://www.gstatic.com/mobilesdk/170329_assistant/assistant_color_28dp.png",
  "parentMenuSectionId": {
    "@id": "27",
    "displayOrder": 1
  }
} {
  "@type": "MenuItemOffer",
  "@id": "3",
  "sku": "offer-cold-brew-coffee",
  "menuItemId": "3",
  "price": 8.50,
  "priceCurrency": "AUD"
} {
  "@type": "MenuItem",
  "@id": "4",
  "name": "English Breakfast Tea",
  "description": "Not Coffee. Try our tea",
  "image": "https://www.gstatic.com/mobilesdk/170329_assistant/assistant_color_28dp.png",
  "parentMenuSectionId": {
    "@id": "27",
    "displayOrder": 2
  }
} {
  "@type": "MenuItemOffer",
  "@id": "4",
  "sku": "offer-english-breakfast-tea",
  "menuItemId": "4",
  "price": 5.50,
  "priceCurrency": "AUD"
} {
  "@type": "Availability",
  "@id": "85343705",
  "availabilityStarts": "11:30",
  "availabilityEnds": "14:30"
} {
  "@type": "MenuSection",
  "@id": "53",
  "menuId": {
    "@id": "1535",
    "displayOrder": 2
  },
  "name": "Lunch (Available 11:30am - 2:30pm)",
  "menuItemId": ["5", "6"],
  "availabilityId": ["85343705"]
} {
  "@type": "MenuItem",
  "@id": "5",
  "name": "Bibimbap",
  "description": "pulled pork, julienned carrot, cucumber, spring onions, brown rice, pureed kimchi, fried free-range egg.",
  "image": "https://www.gstatic.com/mobilesdk/170329_assistant/assistant_color_28dp.png",
  "parentMenuSectionId": {
    "@id": "53",
    "displayOrder": 1
  }
} {
  "@type": "Availability",
  "@id": "54767",
  "availabilityStarts": "12:00",
  "availabilityEnds": "13:00"
} {
  "@type": "MenuItemOffer",
  "@id": "753",
  "sku": "offer-bibimbap",
  "menuItemId": "5",
  "price": 24.80,
  "priceCurrency": "AUD",
  "availabilityId": ["54767"]
} {
  "@type": "MenuItem",
  "@id": "6",
  "name": "The Big Chicken",
  "description": "WA free range handmade chicken burger, lettuce, avocado, bacon, tomato relish on charcoal brioche bun, sweet potato wedges and house made aioli (vegetarian option – spiced lentil burger, just ask us in the notes)",
  "image": "https://www.gstatic.com/mobilesdk/170329_assistant/assistant_color_28dp.png",
  "parentMenuSectionId": {
    "@id": "53",
    "displayOrder": 2
  }
} {
  "@type": "MenuItemOffer",
  "@id": "856",
  "sku": "offer-big-chicken",
  "menuItemId": "6",
  "price": 25.60,
  "priceCurrency": "AUD"
}

JSON

أصناف قائمة الطعام التي تتضمّن عروضًا تختلف حسب السعر والوقت.

تحتوي القائمة على قسمين. عنصر القائمة "معكرونة" له حقلان مطابقان MenuItemOffer عناصر (عنصر واحد بسعر الغداء والآخر لتناول العشاء السعر). يبلغ سعر الغداء للمعكرونة 7.49 دولار أمريكي، وسعر العشاء 10.49 دولارًا.

{
  "@type": "Menu",
  "name": "Dine-In Menu",
  "@id": "1535"
} {
  "@type": "MenuSection",
  "@id": "4371",
  "menuId": {
    "@id": "1535",
    "displayOrder": 1
  },
  "name": "Main",
  "description": "Main course",
  "image": "http://www.provider.com/somerestaurant/main_dishes.jpg",
  "menuItemId": ["1", "2"]
} {
  "@type": "MenuItem",
  "@id": "1",
  "name": "Pizza",
  "description": "Pizza",
  "image": "http://www.provider.com/somerestaurant/menuitem/1",
  "parentMenuSectionId": {
    "@id": "4371",
    "displayOrder": 1
  }
} {
  "@type": "Availability",
  "@id": "morning_availability",
  "availabilityStarts": "08:00",
  "availabilityEnds": "18:00"
} {
  "@type": "Availability",
  "@id": "evening_availability",
  "availabilityStarts": "18:00",
  "availabilityEnds": "21:00"
} {
  "@type": "MenuItemOffer",
  "@id": "6680262",
  "sku": "offer-pizza",
  "menuItemId": "1",
  "price": 7.49,
  "priceCurrency": "USD",
  "availabilityId": ["morning_availability"]
} //Starts at 8:00AM, ends at 6:00PM, last order at 5:59:59PM
{
  "@type": "MenuItem",
  "@id": "2",
  "name": "Pasta",
  "description": "Pasta",
  "image": "http://www.provider.com/somerestaurant/menuitem/2",
  "parentMenuSectionId": {
    "@id": "4371",
    "displayOrder": 2
  }
} {
  "@type": "MenuItemOffer",
  "@id": "5472",
  "sku": "offer-pasta-lunch",
  "menuItemId": "2",
  "price": 7.49,
  "priceCurrency": "USD",
  "availabilityId": ["morning_availability"]
} //Starts at 8:00AM, ends at 6:00PM, last order at 5:59:59PM
{
  "@type": "MenuItemOffer",
  "@id": "174",
  "sku": "offer-pasta-dinner",
  "menuItemId": "2",
  "price": 10.49,
  "priceCurrency": "USD",
  "availabilityId": ["evening_availability"]
} //Starts at 6:00PM, ends at 9:00PM, last order at 8:59:59PM
{
  "@type": "MenuSection",
  "@id": "753",
  "menuId": {
    "@id": "1535",
    "displayOrder": 2
  },
  "name": "Soups & Salads",
  "description": "Salads and a few choices of soup",
  "image": "https://www.provider.com/somerestaurant/soup_and_salad_dishes.jpg",
  "menuItemId": ["3"]
} {
  "@type": "MenuItem",
  "@id": "3",
  "name": "Pea Soup",
  "description": "Creamy pea soup topped with melted cheese and sourdough croutons.",
  "parentMenuSectionId": {
    "@id": "1535",
    "displayOrder": 1
  }
} {
  "@type": "MenuItemOffer",
  "@id": "9763",
  "sku": "offer-pea-soup",
  "menuItemId": "3",
  "price": 3.49,
  "priceCurrency": "USD"
} //Starts at 8:00AM, ends at 6:00PM, last order at 5:59:59PM

التخصيص باستخدام الإضافات

يمكن أن تحتوي العناصر في القائمة على خيارات إضافية للإضافات. تحديد الإضافات لـ MenuItem من خلال الإشارة إلى MenuSection عنصر باستخدام menuAddOnId. تلك MenuSection يجب أن يحتوي على عناصر القائمة المستخدمة للإضافات.

يمكنك توفير عناصر "MenuItem" للإضافة التلقائية باستخدام "defaultOptionId". لكائن الإضافة MenuSection.

حالة الاستخدام أفضل ممارسة
حالة الاستخدام 1: الإضافات الأساسية استخدام عنصر MenuSection للإضافة eligibleQuantityMin وeligibleQuantityMax والخصائص لتحديد الحد الأدنى والأقصى لعدد عناصر الإضافة التي يمكن تحديدها من قسم الوظائف الإضافية.
حالة الاستخدام 2: الإضافات التلقائية استخدام عنصر MenuSection للإضافة defaultOptionId لتوفير خيارات الإضافة التلقائية.
حالة الاستخدام 3: وجبات الطعام المختلطة/التغليف استخدِم كائنات MenuSection لوصف الخيارات التي يمكن للمستخدم اتخاذها عند اختيار طبق أو مزيج من الأطباق.

JSON

في هذا المثال، تشير كلمة "كابتشينو" صنف في القائمة قابل للتخصيص باستخدام قشة الخيار.

هناك خيار إضافي واحد إضافي متاح لـ "كعكة البيغل على البحر الأبيض المتوسط" صنف في عمود "الطعام طوال اليوم" بالإضافة إلى إضافتين من البيض الخيارات.

The "Club Bagel" عنصر واحد في قسم القائمة نفسه يحتوي على الميزات الإضافية نفسها الوظائف الإضافية المتاحة، بالإضافة إلى "خيارات البيض" خيار إضافي للبيض المخفوق.

في قسم المشروبات، يتوفّر صنف واحد يشمل "اللبن" و"خيار القش" خيار الإضافة.

{
  "@type": "Menu",
  "name": "Coffee Shop A",
  "@id": "1535"
} {
  "@type": "MenuSection",
  "@id": "4371",
  "menuId": {
    "@id": "1535",
    "displayOrder": 1
  },
  "name": "All day food",
  "menuItemId": ["1", "12"]
} {
  "@type": "MenuItem",
  "@id": "1",
  "name": "Mediterranean Bagel",
  "description": "rocket, scrambled egg, tomato relish, bacon ***Gluten free bagel available***",
  "image": "https://www.gstatic.com/mobilesdk/170329_assistant/assistant_color_28dp.png"
} {
  "@type": "MenuItemOffer",
  "@id": "6680262",
  "sku": "offer-mediterranean-bagel",
  "menuItemId": "1",
  "price": 17.60,
  "priceCurrency": "AUD"
} {
  "@type": "MenuSection",
  "@id": "362",
  "name": "Extras",
  "menuItemId": ["2"],
  "parentMenuItemId": [{
    "@id": "1",
    "displayOrder": 1
  }]
} {
  "@type": "MenuItem",
  "@id": "2",
  "name": "Chorizo"
} {
  "@type": "MenuItemOffer",
  "@id": "74",
  "sku": "offer-addon-chorizo",
  "menuItemId": "2",
  "price": 6.00,
  "priceCurrency": "AUD",
  "eligibleQuantityMax": 1
} {
  "@type": "MenuSection",
  "@id": "5374",
  "name": "Egg Options",
  "menuItemId": ["8", "9"],
  "parentMenuItemId": [{
    "@id": "1",
    "displayOrder": 1
  }],
  "eligibleQuantityMin": 1,
  "eligibleQuantityMax": 2
} {
  "@type": "MenuItem",
  "@id": "8",
  "name": "No Extra Egg"
} {
  "@type": "MenuItemOffer",
  "@id": "4527",
  "sku": "offer-addon-no-egg",
  "menuItemId": "8",
  "price": 0.00,
  "priceCurrency": "AUD",
  "eligibleQuantityMax": 1
} {
  "@type": "MenuItem",
  "@id": "9",
  "name": "Extra Egg - Fried"
} {
  "@type": "MenuItemOffer",
  "@id": "99",
  "sku": "offer-addon-fried-egg",
  "menuItemId": "9",
  "price": 3.00,
  "priceCurrency": "AUD",
  "eligibleQuantityMax": 1
} {
  "@type": "MenuItem",
  "@id": "12",
  "name": "Club Bagel",
  "description": "grilled chicken, bacon, rocket, tomato relish ***Gluten Free Bagels Available***",
  "image": "https://www.gstatic.com/mobilesdk/170329_assistant/assistant_color_28dp.png"
} {
  "@type": "MenuItemOffer",
  "@id": "428",
  "sku": "offer-club-empire-bagel",
  "menuItemId": "12",
  "price": 18.90,
  "priceCurrency": "AUD"
} {
  "@type": "MenuSection",
  "@id": "3865",
  "name": "Extras",
  "menuItemId": ["2", "13"],
  "parentMenuItemId": [{
    "@id": "12",
    "displayOrder": 1
  }],
  "eligibleQuantityMin": 0,
  "eligibleQuantityMax": 2
} {
  "@type": "MenuItem",
  "@id": "13",
  "name": "Free Range Bacon"
} {
  "@type": "MenuItemOffer",
  "@id": "832",
  "sku": "offer-addon-bacon",
  "menuItemId": "13",
  "price": 6.00,
  "priceCurrency": "AUD",
  "eligibleQuantityMax": 1
} {
  "@type": "MenuSection",
  "@id": "5428",
  "name": "Egg Options",
  "menuItemId": ["8", "9", "14"],
  "parentMenuItemId": [{
    "@id": "12",
    "displayOrder": 1
  }],
  "eligibleQuantityMin": 1,
  "eligibleQuantityMax": 2
} {
  "@type": "MenuItem",
  "@id": "14",
  "name": "Scrambled Egg"
} {
  "@type": "MenuItemOffer",
  "@id": "546",
  "sku": "offer-scrambled-egg",
  "menuItemId": "14",
  "price": 3.00,
  "priceCurrency": "AUD",
  "eligibleQuantityMax": 1
} {
  "@type": "MenuSection",
  "@id": "531",
  "menuId": {
    "@id": "1535",
    "displayOrder": 2
  },
  "name": "Lunch (Available 11:30am - 2:30pm)",
  "menuItemId": ["15"]
} {
  "@type": "MenuItem",
  "@id": "15",
  "name": "Bibimbap",
  "description": "pulled pork, julienned carrot, cucumber, spring onions, brown rice, pureed kimchi, fried free-range egg.",
  "image": "https://www.gstatic.com/mobilesdk/170329_assistant/assistant_color_28dp.png"
} {
  "@type": "MenuItemOffer",
  "@id": "753",
  "sku": "offer-bibimbap",
  "menuItemId": "15",
  "price": 24.80,
  "priceCurrency": "AUD"
} {
  "@type": "MenuSection",
  "@id": "27",
  "menuId": {
    "@id": "1535",
    "displayOrder": 3
  },
  "name": "Drinks",
  "menuItemId": ["17"]
} {
  "@type": "MenuItem",
  "@id": "17",
  "name": "Cappuccino",
  "description": "Milk Foam over a cup of espresso, topped with chocolate powder art",
  "image": "https://www.gstatic.com/mobilesdk/170329_assistant/assistant_color_28dp.png"
} {
  "@type": "MenuItemOffer",
  "@id": "1743",
  "sku": "offer-cappucino",
  "menuItemId": "17",
  "price": 6.50,
  "priceCurrency": "AUD"
} {
  "@type": "MenuSection",
  "@id": "4527",
  "name": "Milk",
  "menuItemId": ["18"],
  "parentMenuItemId": [{
    "@id": "17",
    "displayOrder": 1
  }],
  "eligibleQuantityMin": 1,
  "eligibleQuantityMax": 1
} {
  "@type": "MenuItem",
  "@id": "18",
  "name": "Skim"
} {
  "@type": "MenuItemOffer",
  "@id": "4588",
  "sku": "offer-addon-skim-milk",
  "menuItemId": "18",
  "price": 0.00,
  "priceCurrency": "AUD",
  "eligibleQuantityMax": 1
} {
  "@type": "MenuSection",
  "@id": "5427",
  "name": "Straw Option",
  "menuItemId": ["22"],
  "parentMenuItemId": [{
    "@id": "17",
    "displayOrder": 1
  }],
  "eligibleQuantityMin": 1,
  "eligibleQuantityMax": 1
} {
  "@type": "MenuItem",
  "@id": "22",
  "name": "Plastic Straw"
} {
  "@type": "MenuItemOffer",
  "@id": "4587",
  "sku": "offer-addon-plastic-straw",
  "menuItemId": "22",
  "price": 0.05,
  "priceCurrency": "AUD",
  "eligibleQuantityMax": 1
}

JSON

في هذا المثال، يحتوي إعلان "Club Bagel" عنصر القائمة محدد مسبقًا باستخدام طبق تشوريزو والبيض المخفوق. أطباق تشوريزو وصلصة الفلفل الحار هي "المأكولات الإضافية" الافتراضية والبيض المخفوق هو النوع التلقائي "خيار البيض" الإضافية.

{
  "@type": "Menu",
  "name": "Coffee Shop A",
  "@id": "1535"
} {
  "@type": "MenuSection",
  "@id": "4371",
  "menuId": {
    "@id": "1535",
    "displayOrder": 1
  },
  "name": "All day food",
  "menuItemId": ["1", "12"]
} {
  "@type": "MenuItem",
  "@id": "1",
  "name": "Mediterranean Bagel",
  "description": "rocket, scrambled egg, tomato relish, bacon ***Gluten free bagel available***",
  "image": "https://www.gstatic.com/mobilesdk/170329_assistant/assistant_color_28dp.png"
} {
  "@type": "MenuItemOffer",
  "@id": "6680262",
  "sku": "offer-mediterranean-bagel",
  "menuItemId": "1",
  "price": 17.60,
  "priceCurrency": "AUD"
} {
  "@type": "MenuSection",
  "@id": "362",
  "name": "Extras",
  "menuItemId": ["2"],
  "parentMenuItemId": [{
    "@id": "1",
    "displayOrder": 1
  }]
} {
  "@type": "MenuItem",
  "@id": "2",
  "name": "Chorizo"
} {
  "@type": "MenuItemOffer",
  "@id": "74",
  "sku": "offer-addon-chorizo",
  "menuItemId": "2",
  "price": 6.00,
  "priceCurrency": "AUD",
  "eligibleQuantityMax": 1
} {
  "@type": "MenuSection",
  "@id": "5374",
  "name": "Egg Options",
  "menuItemId": ["8", "9"],
  "parentMenuItemId": [{
    "@id": "1",
    "displayOrder": 1
  }],
  "eligibleQuantityMin": 1,
  "eligibleQuantityMax": 2
} {
  "@type": "MenuItem",
  "@id": "8",
  "name": "No Extra Egg"
} {
  "@type": "MenuItemOffer",
  "@id": "4527",
  "sku": "offer-addon-no-egg",
  "menuItemId": "8",
  "price": 0.00,
  "priceCurrency": "AUD",
  "eligibleQuantityMax": 1
} {
  "@type": "MenuItem",
  "@id": "9",
  "name": "Extra Egg - Fried"
} {
  "@type": "MenuItemOffer",
  "@id": "99",
  "sku": "offer-addon-fried-egg",
  "menuItemId": "9",
  "price": 3.00,
  "priceCurrency": "AUD",
  "eligibleQuantityMax": 1
} {
  "@type": "MenuItem",
  "@id": "12",
  "name": "Club Bagel",
  "description": "grilled chicken, bacon, rocket, tomato relish ***Gluten Free Bagels Available***",
  "image": "https://www.gstatic.com/mobilesdk/170329_assistant/assistant_color_28dp.png"
} {
  "@type": "MenuItemOffer",
  "@id": "428",
  "sku": "offer-club-empire-bagel",
  "menuItemId": "12",
  "price": 18.90,
  "priceCurrency": "AUD"
} {
  "@type": "MenuSection",
  "@id": "3865",
  "name": "Extras",
  "menuItemId": ["2", "13", "25"],
  "parentMenuItemId": [{
    "@id": "12",
    "displayOrder": 1
  }],
  "eligibleQuantityMin": 0,
  "eligibleQuantityMax": 2,
  "defaultItemId": ["2", "25"]
} {
  "@type": "MenuItem",
  "@id": "13",
  "name": "Free Range Bacon"
} {
  "@type": "MenuItemOffer",
  "@id": "832",
  "sku": "offer-addon-bacon",
  "menuItemId": "13",
  "price": 6.00,
  "priceCurrency": "AUD",
  "eligibleQuantityMax": 1
} {
  "@type": "MenuItem",
  "@id": "25",
  "name": "Chili Sauce"
} {
  "@type": "MenuItemOffer",
  "@id": "7337",
  "sku": "offer-addon-chili-sauce",
  "menuItemId": "25",
  "price": 0.00,
  "priceCurrency": "AUD",
  "eligibleQuantityMax": 1
} {
  "@type": "MenuSection",
  "@id": "5428",
  "name": "Egg Options",
  "menuItemId": ["8", "9", "14"],
  "parentMenuItemId": [{
    "@id": "12",
    "displayOrder": 1
  }],
  "eligibleQuantityMin": 1,
  "eligibleQuantityMax": 2,
  "defaultItemId": ["14"]
} {
  "@type": "MenuItem",
  "@id": "14",
  "name": "Scrambled Egg"
} {
  "@type": "MenuItemOffer",
  "@id": "546",
  "sku": "offer-scrambled-egg",
  "menuItemId": "14",
  "price": 3.00,
  "priceCurrency": "AUD",
  "eligibleQuantityMax": 1
} {
  "@type": "MenuSection",
  "@id": "27",
  "menuId": {
    "@id": "1535",
    "displayOrder": 3
  },
  "name": "Drinks",
  "menuItemId": ["17"]
} {
  "@type": "MenuItem",
  "@id": "17",
  "name": "Cappuccino",
  "description": "Milk Foam over a cup of espresso, topped with chocolate powder art",
  "image": "https://www.gstatic.com/mobilesdk/170329_assistant/assistant_color_28dp.png"
} {
  "@type": "MenuItemOffer",
  "@id": "1743",
  "sku": "offer-cappucino",
  "menuItemId": "17",
  "price": 6.50,
  "priceCurrency": "AUD"
} {
  "@type": "MenuSection",
  "@id": "4527",
  "name": "Milk",
  "menuItemId": ["18"],
  "parentMenuItemId": [{
    "@id": "17",
    "displayOrder": 1
  }, {
    "@id": "24",
    "displayOrder": 2
  }],
  "eligibleQuantityMin": 1,
  "eligibleQuantityMax": 1
} {
  "@type": "MenuItem",
  "@id": "18",
  "name": "Skim"
} {
  "@type": "MenuItemOffer",
  "@id": "4588",
  "sku": "offer-addon-skim-milk",
  "menuItemId": "18",
  "price": 0.00,
  "priceCurrency": "AUD",
  "eligibleQuantityMax": 1
} {
  "@type": "MenuSection",
  "@id": "5427",
  "name": "Straw Option",
  "menuItemId": ["22"],
  "parentMenuItemId": [{
    "@id": "17",
    "displayOrder": 1
  }, {
    "@id": "24",
    "displayOrder": 2
  }],
  "eligibleQuantityMin": 1,
  "eligibleQuantityMax": 1
} {
  "@type": "MenuItem",
  "@id": "22",
  "name": "Plastic Straw"
} {
  "@type": "MenuItemOffer",
  "@id": "4587",
  "sku": "offer-addon-plastic-straw",
  "menuItemId": "22",
  "price": 0.05,
  "priceCurrency": "AUD",
  "eligibleQuantityMax": 1
}

JSON

يحتوي هذا المثال على وجبة مجمعة تتكون من برغر وبطاطا مقلية ومشروب. يمكن تخصيص كل صنف من الطعام بإضافة إضافات و والإضافات.

تشمل الوجبة المختلطة برغر وبطاطس مقلية ومشروبًا واحدًا كشرط للحصول على المستخدم اختياره. يتوفّر خياران للبرغر، ولكل منهما مطعم إضافي. الأقسام: "وصفة طعام" (عنصرين في القائمة، على المستخدم اختيار من 0 إلى 1 خيار) "ميزات إضافية" (ثلاثة عناصر قائمة، على المستخدم اختيار من 0 إلى 3 خيارات).

{
  "@type": "Menu",
  "name": "FastFood B",
  "@id": "1535"
} {
  "@type": "MenuSection",
  "@id": "4371",
  "menuId": {
    "@id": "1535",
    "displayOrder": 1
  },
  "name": "Combo Meals",
  "menuItemId": ["1"]
} {
  "@type": "MenuItem",
  "@id": "1",
  "name": "Burger Combo ABox",
  "description": "1 Burger, 1 Fries, 1 Drink",
  "image": "https://www.gstatic.com/mobilesdk/170329_assistant/assistant_color_28dp.png"
} {
  "@type": "MenuItemOffer",
  "@id": "6680262",
  "sku": "offer-burger-combo-a",
  "menuItemId": "1",
  "price": 16.95,
  "priceCurrency": "AUD"
} {
  "@type": "MenuSection",
  "@id": "362",
  "name": "Burger",
  "menuItemId": ["2", "3"],
  "parentMenuItemId": [{
    "@id": "1",
    "displayOrder": 1
  }],
  "eligibleQuantityMin": 1,
  "eligibleQuantityMax": 1
} {
  "@type": "MenuItem",
  "@id": "2",
  "name": "Fillet Burger"
} {
  "@type": "MenuItemOffer",
  "@id": "74",
  "sku": "offer-burger-fillet",
  "menuItemId": "2",
  "price": 0.00,
  "priceCurrency": "AUD"
} {
  "@type": "MenuItem",
  "@id": "3",
  "name": "Zinger filler Burger"
} {
  "@type": "MenuItemOffer",
  "@id": "42",
  "sku": "offer-burger-zinger-filler",
  "menuItemId": "3",
  "price": 0.00,
  "priceCurrency": "AUD",
  "eligibleQuantityMax": 1
} {
  "@type": "MenuSection",
  "@id": "5374",
  "name": "Recipe",
  "menuItemId": ["13", "25"],
  "parentMenuItemId": [{
    "@id": "2",
    "displayOrder": 1
  }, {
    "@id": "3",
    "displayOrder": 1
  }],
  "eligibleQuantityMin": 0,
  "eligibleQuantityMax": 1
} {
  "@type": "MenuItem",
  "@id": "13",
  "name": "Lettuce"
} {
  "@type": "MenuItemOffer",
  "@id": "832",
  "sku": "offer-lettuce",
  "menuItemId": "13",
  "price": 0.00,
  "priceCurrency": "AUD"
} {
  "@type": "MenuItem",
  "@id": "25",
  "name": "Mayo"
} {
  "@type": "MenuItemOffer",
  "@id": "7337",
  "sku": "offer-mayo",
  "menuItemId": "25",
  "price": 0.00,
  "priceCurrency": "AUD"
} {
  "@type": "MenuSection",
  "@id": "3865",
  "name": "Extras",
  "menuItemId": ["22", "23", "24"],
  "parentMenuItemId": [{
    "@id": "2",
    "displayOrder": 1
  },
  {
    "@id": "3",
    "displayOrder": 1
  }],
  "eligibleQuantityMin": 0,
  "eligibleQuantityMax": 3
} {
  "@type": "MenuItem",
  "@id": "22",
  "name": "Bacon Slice"
} {
  "@type": "MenuItemOffer",
  "@id": "4588",
  "sku": "offer-extra-bacon-slice",
  "menuItemId": "22",
  "price": 0.50,
  "priceCurrency": "AUD",
  "eligibleQuantityMax": 10
} {
  "@type": "MenuItem",
  "@id": "23",
  "name": "Cheese Slice"
} {
  "@type": "MenuItemOffer",
  "@id": "53865",
  "sku": "offer-extra-cheese-slice",
  "menuItemId": "23",
  "price": 0.50,
  "priceCurrency": "AUD",
  "eligibleQuantityMax": 10
} {
  "@type": "MenuItem",
  "@id": "24",
  "name": "Coleslaw"
} {
  "@type": "MenuItemOffer",
  "@id": "3",
  "sku": "offer-extra-coleslaw",
  "menuItemId": "24",
  "price": 0.30,
  "priceCurrency": "AUD",
  "eligibleQuantityMax": 10
} {
  "@type": "MenuSection",
  "@id": "5428",
  "name": "Fries",
  "menuItemId": ["14"],
  "parentMenuItemId": [{
    "@id": "1",
    "displayOrder": 2
  }],
  "eligibleQuantityMin": 1,
  "eligibleQuantityMax": 1
} {
  "@type": "MenuItem",
  "@id": "14",
  "name": "Regular Fries"
} {
  "@type": "MenuItemOffer",
  "@id": "546",
  "sku": "offer-fries",
  "menuItemId": "14",
  "price": 0.00,
  "priceCurrency": "AUD"
} {
  "@type": "MenuSection",
  "@id": "27",
  "name": "Drinks",
  "menuItemId": ["17", "18"],
  "parentMenuItemId": [{
    "@id": "1",
    "displayOrder": 3
  }],
  "eligibleQuantityMin": 1,
  "eligibleQuantityMax": 1
} {
  "@type": "MenuItem",
  "@id": "17",
  "name": "Regular Pepsi Max"
} {
  "@type": "MenuItemOffer",
  "@id": "1743",
  "sku": "offer-pepsi-max",
  "menuItemId": "17",
  "price": 0.00,
  "priceCurrency": "AUD",
  "eligibleQuantityMax": 2
} {
  "@type": "MenuItem",
  "@id": "18",
  "name": "Regular Pepsi"
} {
  "@type": "MenuItemOffer",
  "@id": "4587",
  "sku": "offer-pepsi",
  "menuItemId": "18",
  "price": 0.00,
  "priceCurrency": "AUD",
  "eligibleQuantityMax": 2
}

التخصيص باستخدام خيارات عناصر القائمة

يمكنك توفير خيارات مختلفة لـ "MenuItem" من خلال الإشارة إليها في السمة menuItemId من MenuItemOption.

على سبيل المثال، إذا كانت البيتزا متاحة بأحجام مختلفة، فيمكنك إنشاء MenuItemOption لكل حجم والرجوع إلى عنصر قائمة البيتزا في السمة menuItemId لكل MenuItemOption.

حالة الاستخدام أفضل ممارسة
حالة الاستخدام 1: بيتزا بأحجام مختلفة استخدام MenuItemOption وMenuItemOffer
حالة الاستخدام 2: بيتزا قابلة للتخصيص بإضافات مختلفة وأحجام استخدام MenuItemOption وMenuItemOffer للتغيير أسعار الإضافات بناءً على حجم البيتزا.
حالة الاستخدام 3: بيتزا قابلة للتخصيص مع اختلافات بين الجانبان الأيسر والأيمن استخدِم السمة value لـ MenuItemOption من أجل لتحديد جانب البيتزا. يمكنك استخدام price و priceCurrency موقع من MenuItemOffer إلى تحديد السعر لكل جانب البيتزا.

NDJSON

البيتزا لها 3 أحجام مختلفة وتتطلب اختيار المستخدم. سعر لكل حجم مختلف.

تبلغ تكلفة فطائر هاواي 10.00 دولار أمريكي صغير، و15.00 دولار للمتوسط و20.00 دولار أمريكي. لبيتزا كبيرة.

{"@type":"Menu","name":"A's Pizza","@id":"menu-1"}
{"@type":"MenuSection","@id":"pizza-section","menuId":{"@id":"menu-1","displayOrder":1},"name":"Pizzas","menuItemId":["piz-hwn"]}
{"@type":"MenuItem","@id":"piz-hwn","name":"Hawaiian Pizza"}
{"@type":"MenuItemOption","@id":"piz-hwn-opt-sml","menuItemId":{"@id":"piz-hwn","displayOrder":1}, "optionType": "SIZE", "value": "Small"}
{"@type":"MenuItemOption","@id":"piz-hwn-opt-med","menuItemId":{"@id":"piz-hwn","displayOrder":2}, "optionType": "SIZE", "value": "Medium"}
{"@type":"MenuItemOption","@id":"piz-hwn-opt-lge","menuItemId":{"@id":"piz-hwn","displayOrder":3}, "optionType": "SIZE", "value": "Large"}
{"@type":"MenuItemOffer","@id":"piz-hwn-off-sml","sku":"123456","menuItemOptionId":"piz-hwn-opt-sml","price":10.00,"priceCurrency":"USD"}
{"@type":"MenuItemOffer","@id":"piz-hwn-off-med","sku":"123457","menuItemOptionId":"piz-hwn-opt-med","price":15.00,"priceCurrency":"USD"}
{"@type":"MenuItemOffer","@id":"piz-hwn-off-lge","sku":"123458","menuItemOptionId":"piz-hwn-opt-lge","price":20.00,"priceCurrency":"USD"}

NDJSON

تختلف أسعار إضافات البيتزا حسب حجم البيتزا.

تبلغ تكلفة بيتزا Pepperoni 10.00 دولارات لقطعة صغيرة، و15.00 دولارًا للوسط، 20.00 دولار أمريكي كبيرة. تكلفة إضافة اللحم البقري هي 1.00 دولار أمريكي على لوح صغير بسعر 1.50 دولار على وسيط، ودولارين أمريكيين على صغير كبير.

{"@type":"Menu","name":"A's Pizza","@id":"menu-1"}
{"@type":"MenuSection","@id":"pizza-section","menuId":{"@id":"menu-1","displayOrder":1},"name":"Pizzas","menuItemId":["piz-pep"]}
{"@type":"MenuItem","@id":"piz-pep","name":"Hawaiian Pizza"}
{"@type":"MenuItemOption","@id":"piz-pep-opt-sml","menuItemId":{"@id":"piz-pep","displayOrder":1}, "optionType": "SIZE", "value": "Small"}
{"@type":"MenuItemOption","@id":"piz-pep-opt-med","menuItemId":{"@id":"piz-pep","displayOrder":2}, "optionType": "SIZE", "value": "Medium"}
{"@type":"MenuItemOption","@id":"piz-pep-opt-lge","menuItemId":{"@id":"piz-pep","displayOrder":3}, "optionType": "SIZE", "value": "Large"}
{"@type":"MenuItemOffer","@id":"piz-pep-off-sml","sku":"123456","menuItemOptionId":"piz-pep-opt-sml","price":10.00,"priceCurrency":"USD"}
{"@type":"MenuItemOffer","@id":"piz-pep-off-med","sku":"123457","menuItemOptionId":"piz-pep-opt-med","price":15.00,"priceCurrency":"USD"}
{"@type":"MenuItemOffer","@id":"piz-pep-off-lge","sku":"123458","menuItemOptionId":"piz-pep-opt-lge","price":20.00,"priceCurrency":"USD"}
{"@type": "MenuSection","@id": "topping-section","menuId": {"@id": "menu-1","displayOrder": 2},"name": "Choice of toppings","menuItemId": ["top-bef-sal"],"parentMenuItemId": [{"@id": "piz-pep","displayOrder": 1}]}
{"@type": "MenuItem","@id": "top-bef-sal","name": "Beef Salami","parentMenuSectionId": {"@id": "topping-section","displayOrder": 1}}
{"@type": "MenuItemOption","@id": "opt-bef-sal-sml","menuItemId": {"@id": "top-bef-sal", "displayOrder": "1"},"applicableParentOptionValue": "Small"}
{"@type": "MenuItemOption","@id": "opt-bef-sal-med","menuItemId": {"@id": "top-bef-sal", "displayOrder": "2"},"applicableParentOptionValue": "Medium"}
{"@type": "MenuItemOption","@id": "opt-bef-sal-lge","menuItemId": {"@id": "top-bef-sal", "displayOrder": "3"},"applicableParentOptionValue": "Large"}
{"@type": "MenuItemOffer","@id": "bef-sal-off-sml","sku": "123561","menuItemOptionId": "opt-bef-sal-sml","price": 1.00,"priceCurrency": "USD"}
{"@type": "MenuItemOffer","@id": "bef-sal-off-med","sku": "123562","menuItemOptionId": "opt-bef-sal-med","price": 1.50,"priceCurrency": "USD"}
{"@type": "MenuItemOffer","@id": "bef-sal-off-lge","sku": "123563","menuItemOptionId": "opt-bef-sal-lge","price": 2.00,"priceCurrency": "USD"}

NDJSON

يمكن إضافة إضافات البيتزا إلى النصف الأيسر أو الأيمن أو الكامل بِيتْزَا. تختلف الأسعار حسب حجم البيتزا، وكذلك حسب الأماكن التي تشملها الإضافات. تطبيقها.

تبلغ تكلفة بيتزا Pepperoni صغيرة 10.00 دولارات لقطعة صغيرة، و15.00 دولارًا للوسط، 20.00 دولار أمريكي كبيرة. تحتوي البيتزا على إضافتين (لحم البقر السلامي والموتزاريلا)، وتبلغ تكلفة كل طبقة علوية للجانبين الأيسر والأيمن من بيتزا صغيرة 1.00 دولار لكل جانب، ولكن 0.50 دولار بدلاً من ذلك للبيتزا الصغيرة بأكملها. تكلفة الإضافات 1.50 دولار لكل جانب للجانبين الأيسر والأيمن من البيتزا المتوسطة، ولكن 1.00 دولار بدلاً من ذلك للبيتزا المتوسطة بالكامل. تكلف الإضافات 2.00 دولار لكل جانب على اليسار الجوانب اليمنى للبيتزا الكبيرة، ولكن 1.50 دولار بدلاً من ذلك للكمية الكبيرة بالكامل بِيتْزَا.

{"@type":"Menu","name":"A's Pizza","@id":"menu-1"}
{"@type":"MenuSection","@id":"pizza-section","menuId":{"@id":"menu-1","displayOrder":1},"name":"Pizzas","menuItemId":["piz-pep"]}
{"@type":"MenuItem","@id":"piz-pep","name":"Pepperoni Pizza"}
{"@type":"MenuItemOption","@id":"piz-pep-opt-sml","menuItemId":{"@id":"piz-pep","displayOrder":1}, "optionType": "SIZE", "value": "Small"}
{"@type":"MenuItemOption","@id":"piz-pep-opt-med","menuItemId":{"@id":"piz-pep","displayOrder":2}, "optionType": "SIZE", "value": "Medium"}
{"@type":"MenuItemOption","@id":"piz-pep-opt-lge","menuItemId":{"@id":"piz-pep","displayOrder":3}, "optionType": "SIZE", "value": "Large"}
{"@type":"MenuItemOffer","@id":"piz-pep-off-sml","sku":"123456","menuItemOptionId":"piz-pep-opt-sml","price":10.00,"priceCurrency":"USD"}
{"@type":"MenuItemOffer","@id":"piz-pep-off-med","sku":"123457","menuItemOptionId":"piz-pep-opt-med","price":15.00,"priceCurrency":"USD"}
{"@type":"MenuItemOffer","@id":"piz-pep-off-lge","sku":"123458","menuItemOptionId":"piz-pep-opt-lge","price":20.00,"priceCurrency":"USD"}
{"@type": "MenuSection","@id": "topping-section","name": "Choice of toppings","menuItemId": ["top-bef-sal", "top-moz"],"parentMenuItemId": [{"@id": "piz-pep",  "displayOrder": 1}]}
{"@type": "MenuItem","@id": "top-bef-sal","name": "Beef Salami","parentMenuSectionId": {"@id": "topping-section",  "displayOrder": 1}}
{"@type": "MenuItemOption","@id": "top-bef-sal-opt-left-sm","menuItemId": {"@id": "top-bef-sal","displayOrder": 1},"applicableParentOptionValue": "Small","optionType": "PIZZA_SIDE","value": "PIZZA_SIDE_LEFT"}
{"@type": "MenuItemOffer","@id": "bef-sal-off-left-sm","sku": "546","menuItemOptionId": "top-bef-sal-opt-left-sm","price": 1.00,"priceCurrency": "USD"}
{"@type": "MenuItemOption","@id": "top-bef-sal-opt-right-sm","menuItemId": {"@id": "top-bef-sal","displayOrder": 2},"applicableParentOptionValue": "Small","optionType": "PIZZA_SIDE","value": "PIZZA_SIDE_RIGHT"}
{"@type": "MenuItemOffer","@id": "bef-sal-off-right-sm","sku": "37","menuItemOptionId": "top-bef-sal-opt-right-sm","price": 1.00,"priceCurrency": "USD"}
{"@type": "MenuItemOption","@id": "top-bef-sal-opt-whole-sm","menuItemId": {"@id": "top-bef-sal","displayOrder": 3},"applicableParentOptionValue": "Small","optionType": "PIZZA_SIDE","value": "PIZZA_SIDE_WHOLE"}
{"@type": "MenuItemOffer","@id": "bef-sal-off-whole-sm","sku": "356","menuItemOptionId": "top-bef-sal-opt-whole-sm","price": 0.50,"priceCurrency": "USD"}
{"@type": "MenuItemOption","@id": "top-bef-sal-opt-left-med","menuItemId": {"@id": "top-bef-sal","displayOrder": 1},"applicableParentOptionValue": "Medium","optionType": "PIZZA_SIDE","value": "PIZZA_SIDE_LEFT"}
{"@type": "MenuItemOffer","@id": "bef-sal-off-left-medium","sku": "764","menuItemOptionId": "top-bef-sal-opt-left-med","price": 1.50,"priceCurrency": "USD"}
{"@type": "MenuItemOption","@id": "top-bef-sal-opt-right-med","menuItemId": {"@id": "top-bef-sal","displayOrder": 2},"applicableParentOptionValue": "Medium","optionType": "PIZZA_SIDE","value": "PIZZA_SIDE_RIGHT"}
{"@type": "MenuItemOffer","@id": "bef-sal-off-right-medium","sku": "476","menuItemOptionId": "top-bef-sal-opt-right-med","price": 1.50,"priceCurrency": "USD"}
{"@type": "MenuItemOption","@id": "top-bef-sal-opt-whole-med","menuItemId": {"@id": "top-bef-sal","displayOrder": 3},"applicableParentOptionValue": "Medium","optionType": "PIZZA_SIDE","value": "PIZZA_SIDE_WHOLE"}
{"@type": "MenuItemOffer","@id": "offer-beef-salami-whole-medium","sku": "2354","menuItemOptionId": "top-bef-sal-opt-whole-med","price": 1.00,"priceCurrency": "USD"}
{"@type": "MenuItemOption","@id": "top-bef-sal-opt-left-lg","menuItemId": {"@id": "top-bef-sal","displayOrder": 1},"applicableParentOptionValue": "Large","optionType": "PIZZA_SIDE","value": "PIZZA_SIDE_LEFT"}
{"@type": "MenuItemOffer","@id": "offer-beef-salami-left-large","sku": "56","menuItemOptionId": "top-bef-sal-opt-left-lg","price": 2.00,"priceCurrency": "USD"}
{"@type": "MenuItemOption","@id": "top-bef-sal-opt-right-lg","menuItemId": {"@id": "top-bef-sal","displayOrder": 2},"applicableParentOptionValue": "Large","optionType": "PIZZA_SIDE","value": "PIZZA_SIDE_RIGHT"}
{"@type": "MenuItemOffer","@id": "offer-beef-salami-right-large","sku": "35","menuItemOptionId": "top-bef-sal-opt-right-lg","price": 2.00,"priceCurrency": "USD"}
{"@type": "MenuItemOption","@id": "top-bef-sal-opt-whole-lg","menuItemId": {"@id": "top-bef-sal","displayOrder": 3},"applicableParentOptionValue": "Large","optionType": "PIZZA_SIDE","value": "PIZZA_SIDE_WHOLE"}
{"@type": "MenuItemOffer","@id": "offer-beef-salami-whole-large","sku": "243","menuItemOptionId": "top-bef-sal-opt-whole-lg","price": 1.50,"priceCurrency": "USD"}
{"@type": "MenuItem","@id": "top-moz","name": "Mozzarella","parentMenuSectionId": {"@id": "topping-section",  "displayOrder": 2}}
{"@type": "MenuItemOption","@id": "top-moz-opt-left-sm","menuItemId": {"@id": "top-moz","displayOrder": 1},"applicableParentOptionValue": "Small","optionType": "PIZZA_SIDE","value": "PIZZA_SIDE_LEFT"}
{"@type": "MenuItemOffer","@id": "off-mozz-left-sm","sku": "5643","menuItemOptionId": "top-moz-opt-left-sm","price": 1.00,"priceCurrency": "USD"}
{"@type": "MenuItemOption","@id": "top-moz-opt-right-sm","menuItemId": {"@id": "top-moz","displayOrder": 2},"applicableParentOptionValue": "Small","optionType": "PIZZA_SIDE","value": "PIZZA_SIDE_RIGHT"}
{"@type": "MenuItemOffer","@id": "off-mozz-right-sm","sku": "426","menuItemOptionId": "top-moz-opt-right-sm","price": 1.00,"priceCurrency": "USD"}
{"@type": "MenuItemOption","@id": "top-moz-opt-whole-sm","menuItemId": {"@id": "top-moz","displayOrder": 3},"applicableParentOptionValue": "Small","optionType": "PIZZA_SIDE","value": "PIZZA_SIDE_WHOLE"}
{"@type": "MenuItemOffer","@id": "off-mozz-whole-sm","sku": "7546","menuItemOptionId": "top-moz-opt-whole-sm","price": 0.50,"priceCurrency": "USD"}
{"@type": "MenuItemOption","@id": "top-moz-opt-left-med","menuItemId": {"@id": "top-moz","displayOrder": 1},"applicableParentOptionValue": "Medium","optionType": "PIZZA_SIDE","value": "PIZZA_SIDE_LEFT"}
{"@type": "MenuItemOffer","@id": "off-mozz-left-med","sku": "5465","menuItemOptionId": "top-moz-opt-left-med","price": 1.50,"priceCurrency": "USD"}
{"@type": "MenuItemOption","@id": "top-moz-opt-right-med","menuItemId": {"@id": "top-moz","displayOrder": 2},"applicableParentOptionValue": "Medium","optionType": "PIZZA_SIDE","value": "PIZZA_SIDE_RIGHT"}
{"@type": "MenuItemOffer","@id": "off-mozz-right-med","sku": "76","menuItemOptionId": "top-moz-opt-right-med","price": 1.50,"priceCurrency": "USD"}
{"@type": "MenuItemOption","@id": "top-moz-opt-whole-med","menuItemId": {"@id": "top-moz","displayOrder": 3},"applicableParentOptionValue": "Medium","optionType": "PIZZA_SIDE","value": "PIZZA_SIDE_WHOLE"}
{"@type": "MenuItemOffer","@id": "off-mozz-whole-med","sku": "34","menuItemOptionId": "top-moz-opt-whole-med","price": 1.00,"priceCurrency": "USD"}
{"@type": "MenuItemOption","@id": "top-moz-opt-left-lge","menuItemId": {"@id": "top-moz","displayOrder": 1},"applicableParentOptionValue": "Large","optionType": "PIZZA_SIDE","value": "PIZZA_SIDE_LEFT"}
{"@type": "MenuItemOffer","@id": "off-mozz-left-lge","sku": "5536","menuItemOptionId": "top-moz-opt-left-lge","price": 2.00,"priceCurrency": "USD"}
{"@type": "MenuItemOption","@id": "top-moz-opt-right-lge","menuItemId": {"@id": "top-moz","displayOrder": 2},"applicableParentOptionValue": "Large","optionType": "PIZZA_SIDE","value": "PIZZA_SIDE_RIGHT"}
{"@type": "MenuItemOffer","@id": "off-mozz-right-lge","sku": "545","menuItemOptionId": "top-moz-opt-right-lge","price": 2.00,"priceCurrency": "USD"}
{"@type": "MenuItemOption","@id": "top-moz-opt-whole-lge","menuItemId": {"@id": "top-moz","displayOrder": 3},"applicableParentOptionValue": "Large","optionType": "PIZZA_SIDE","value": "PIZZA_SIDE_WHOLE"}
{"@type": "MenuItemOffer","@id": "off-mozz-whole-lge","sku": "744","menuItemOptionId": "top-moz-opt-whole-lge","price": 1.50,"priceCurrency": "USD"}

الخدمة

يحدّد الكيان Service عملية تسليم طلب الطعام. إجراء من مطعم، مثل نوع الخدمة ساعات الخدمة، المنطقة ورسومها موضحة في ServiceArea وServiceHours OperationHours وFee

يمكن لمطعم واحد تحديد عناصر متعددة للخدمات (على سبيل المثال، إذا كان مطعم ما تدعم خدمات التوصيل وطلب الوجبات الجاهزة لتناولها خارج المطعم)، ولكن يجب تخصيص خدمة واحدة مرتبطة بمطعم واحد من خلال الموقع الإلكتروني serviceType التابع للخدمة

حالة الاستخدام أفضل ممارسة
حالة الاستخدام 1: خدمة التوصيل الأساسية استخدام السمتَين opens وcloses في ServiceHours وOperationHours لتحديد وقت البدء والانتهاء الذي يمكن فيه للمستخدم تنفيذ (إكمال) الطلب تقديم طلب، على التوالي. لتحديد المهلة الزمنية للتسليم ( الوقت المقدَّر للاستلام/التسليم)، يمكنك استخدام leadTimeMin خصائص leadTimeMax من ServiceHours

JSON

تقبل الخدمة النموذجية التالية الطلبات يوميًا من الساعة 8 صباحًا إلى الساعة 6 مساءً. (يمكن تقديم آخر طلب في الساعة 5:59:59 مساءً) من 1 شباط (فبراير) 2016 إلى آذار (مارس) الأول من عام 2016، ويتم تسليمه مع حد أدنى لوقت الانتظار يبلغ ساعة واحدة وحد أقصى للانتظار الوقت لمدة 90 دقيقة. تتوفّر خدمة التوصيل بالرمز البريدي 94041. في الولايات المتحدة. هناك رسوم تسليم 5 دولارات على المستخدم.

{
  "@type": "Service",
  "@id": "10824/delivery",
  "serviceType": "DELIVERY",
  "menuId": "10824",
  "restaurantId": "10824"
} {
  "@type": "ServiceArea",
  "@id": "28427",
  "serviceId": "10824/delivery",
  "postalCode": 94041,
  "addressCountry": "US"
} {
  "@type": "OperationHours",
  "@id": "10824/deliveryOh",
  "serviceId": "10824/delivery",
  "validFrom": "2016-02-01T00:00:00-07:00",
  "validThrough": "2016-03-01T00:00:00-07:00",
  "opens": "T08:00",
  "closes": "T18:00"
} {
  "@type": "ServiceHours",
  "@id": "613741/delivery",
  "orderType": "ASAP",
  "serviceId": "10824/delivery",
  "leadTimeMin": 60,
  "leadTimeMax": 90
} {
  "@type": "Fee",
  "@id": "28427",
  "serviceId": "10824/delivery",
  "feeType": "DELIVERY",
  "priceCurrency": "USD",
  "price": 5.0
}

ساعات التسليم والاستلام

توضّح الأمثلة أدناه كيفية تحديد ساعات التسليم والاستلام خدمة ما.

حالة الاستخدام أفضل ممارسة
حالة الاستخدام 1: ضبط ساعات التسليم استخدام السمتَين leadTimeMin وleadTimeMax مقابل ServiceHours للطلبات في أقرب وقت ممكن. استخدام OperationHours للطلبات المسبقة. يمكنك استخدام خاصية isSpecialHour من ServiceHours OperationHours للتوصيل والطلب خلال العطلة الخاصة ساعات العمل
حالة الاستخدام 2: ضبط ساعات استلام الطلب استخدام السمتَين leadTimeMin وleadTimeMax مقابل ServiceHours للطلبات في أقرب وقت ممكن. استخدام OperationHours للطلبات المسبقة. يمكنك استخدام خاصية isSpecialHour من ServiceHours OperationHours للاستلام والطلب خلال موسم الأعياد ساعة.

JSON

يقبل المطعم خدمات التوصيل في أقرب وقت ممكن ويتلقى الطلبات مقدمًا. وتتيح أيضًا ساعات التسليم الخاصة خلال الأعياد.

في هذا المثال، يمكن للمستخدمين تقديم طلبات عبر الإنترنت في أي وقت. وتتراوح ساعات التسليم خلال أيام الأسبوع من 9 صباحًا إلى 11 مساءً. ساعات التسليم في عطلة نهاية الأسبوع من الساعة 9 صباحًا حتى الساعة 9 مساءً. في 24 كانون الأول (ديسمبر) 2019 على وجه التحديد، تتراوح ساعات التسليم من 9 صباحًا إلى 4. مساءً. توفّر الخدمة حدًا أدنى لوقت انتظار يبلغ ساعة واحدة وحد أقصى. وقت انتظار 90 دقيقة.

يمكن للمستخدمين تقديم الطلبات قبل 6 أيام (8640 دقيقة) إلى ساعة واحدة. مسبقًا في أي يوم، بما في ذلك 24 ديسمبر 2019. يمكن للمستخدمين وضع طلبات التسليم مقدّمًا بزيادات مدتها 15 دقيقة (على سبيل المثال، 8:00 مساءً 8:15 مساءً، 8:30 مساءً). تتوفر خدمة التوصيل في منطقة مضلّعة الموضحة في الرمز، مع فرض رسوم تسليم قدرها 5 دولارات أمريكية على المستخدم.

{
  "@type": "Service",
  "@id": "10824/delivery",
  "serviceType": "DELIVERY",
  "menuId": "10824",
  "restaurantId": "10824"
} {
  "@type": "ServiceArea",
  "@id": "28427",
  "serviceId": "10824/delivery",
  "polygon": ["-20.728777 116.804256 -20.736323 116.8161 -20.722997 116.86468 -20.725406 116.871547 -20.736323 116.873607 -20.7474 116.816444 -20.756871 116.819877 -20.757673 116.788291 -20.740497 116.786403"]
} {
  "@type": "OperationHours",
  "@id": "427/deliveryOh",
  "serviceId": "10824/delivery",
  "opens": "T00:00",
  "closes": "T23:59",
  "isSpecialHour": false
} {
  "@type": "ServiceHours",
  "@id": "613741/delivery",
  "orderType": "ASAP",
  "serviceId": "10824/delivery",
  "operationHoursId":["427/deliveryOh"],
  "opens": "T09:00",
  "closes": "T23:00",
  "dayOfWeek": ["MONDAY", "TUESDAY", "WEDNESDAY", "THURSDAY", "FRIDAY"],
  "leadTimeMin": 60,
  "leadTimeMax": 90,
  "isSpecialHour": false
} {
  "@type": "ServiceHours",
  "@id": "3654/delivery",
  "orderType": "ADVANCE",
  "serviceId": "10824/delivery",
  "operationHoursId":["427/deliveryOh"],
  "opens": "T09:00",
  "closes": "T23:00",
  "dayOfWeek": ["MONDAY", "TUESDAY", "WEDNESDAY", "THURSDAY", "FRIDAY"],
  "advanceBookingRequirementMin": 60,
  "advanceBookingRequirementMax": 8640,
  "advanceBookingSlotInterval": "PT15M",
  "isSpecialHour":false
} {
  "@type": "ServiceHours",
  "@id": "4694/delivery",
  "orderType": "ASAP",
  "serviceId": "10824/delivery",
  "operationHoursId":["427/deliveryOh"],
  "opens": "T09:00",
  "closes": "T21:00",
  "dayOfWeek": ["SATURDAY", "SUNDAY"],
  "leadTimeMin": 60,
  "leadTimeMax": 90,
  "isSpecialHour": false
} {
  "@type": "ServiceHours",
  "@id": "6479/delivery",
  "orderType": "ADVANCE",
  "serviceId": "10824/delivery",
  "operationHoursId":["427/deliveryOh"],
  "opens": "T09:00",
  "closes": "T21:00",
  "dayOfWeek": ["SATURDAY", "SUNDAY"],
  "advanceBookingRequirementMin": 60,
  "advanceBookingRequirementMax": 8640,
  "advanceBookingSlotInterval": "PT15M",
  "isSpecialHour":false
} {
  "@type": "ServiceHours",
  "@id": "3754/delivery",
  "orderType": "ASAP",
  "serviceId": "10824/delivery",
  "validFrom": "2019-12-24T00:00:00+10:00",
  "validThrough": "2019-12-24T23:59:59+10:00",
  "opens": "T09:00",
  "closes": "T16:00",
  "leadTimeMin": 60,
  "leadTimeMax": 90,
  "isSpecialHour": true
} {
  "@type": "Fee",
  "@id": "28427",
  "serviceId": "10824/delivery",
  "feeType": "DELIVERY",
  "priceCurrency": "USD",
  "price": 5.00
}

JSON

يقبل المطعم خدمات الاستلام في أقرب وقت ممكن ويقبل الطلبات المسبقة. أُنشأها جون هنتر، الذي كان متخصصًا بالإضافة إلى ساعات خاصة لاستلام الطلب خلال العطلات

في هذا المثال، يمكن للمستخدمين البدء في الطلب على الإنترنت قبل ساعتين من بدء ساعة الخدمة. وتُقدَّم ساعات الاستلام خلال أيام الأسبوع من الساعة 9 صباحًا إلى الساعة 11 مساءً. ساعات الاستلام خلال عطلة نهاية الأسبوع هي من الساعة 9 صباحًا إلى الساعة 9 مساءً. وفي 24 كانون الأول (ديسمبر) 2019 على وجه التحديد، تبدأ ساعات استلام الطلب من الساعة 9 صباحًا حتى الساعة 4 مساءً. يبلغ الحد الأدنى لوقت الانتظار في استلام الطلب 30 دقيقة والحدّ الأقصى لوقت الانتظار هو 1. ساعة.

يمكن للمستخدمين تقديم الطلبات قبل يومَين (2880 دقيقة) إلى 30 دقيقة. دقيقة عن أي يوم، بما في ذلك 24 ديسمبر 2019. يمكن للمستخدمين يجب تقديم طلبات الاستلام قبل تقديم الطلبات فقط لمدة 15 دقيقة (على سبيل المثال، 8:00 مساءً، 8:15 مساءً، 8:30 مساءً). لا يتم فرض رسوم استلام على المستخدم.

{
  "@type": "Service",
  "@id": "10824/takeout",
  "serviceType": "TAKEOUT",
  "menuId": "10824",
  "restaurantId": "10824"
} {
  "@type": "OperationHours",
  "@id": "427/takeoutOh",
  "serviceId": "10824/takeout",
  "opens": "T07:00",
  "closes": "T23:00",
  "dayOfWeek": ["MONDAY", "TUESDAY", "WEDNESDAY", "THURSDAY", "FRIDAY"]
} {
  "@type": "OperationHours",
  "@id": "2652/takeoutOh",
  "serviceId": "10824/takeout",
  "opens": "T07:00",
  "closes": "T21:00",
  "dayOfWeek": ["SATURDAY", "SUNDAY"]
} {
  "@type": "ServiceHours",
  "@id": "613741/takeout",
  "orderType": "ASAP",
  "serviceId": "10824/takeout",
  "operationHoursId":["427/takeoutOh"],
  "opens": "T09:00",
  "closes": "T23:00",
  "dayOfWeek": ["MONDAY", "TUESDAY", "WEDNESDAY", "THURSDAY", "FRIDAY"],
  "leadTimeMin": 30,
  "leadTimeMax": 60,
  "isSpecialHour": false
} {
  "@type": "ServiceHours",
  "@id": "3654/takeout",
  "orderType": "ADVANCE",
  "serviceId": "10824/takeout",
  "operationHoursId":["427/takeoutOh", "2652/takeoutOh"],
  "opens": "T09:00",
  "closes": "T23:00",
  "dayOfWeek": ["MONDAY", "TUESDAY", "WEDNESDAY", "THURSDAY", "FRIDAY"],
  "advanceBookingRequirementMin": 30,
  "advanceBookingRequirementMax": 2880,
  "advanceBookingSlotInterval": "PT15M",
  "isSpecialHour": false
} {
  "@type": "ServiceHours",
  "@id": "4694/takeout",
  "orderType": "ASAP",
  "serviceId": "10824/takeout",
  "operationHoursId": ["2652/takeoutOh"],
  "opens": "T09:00",
  "closes": "T21:00",
  "dayOfWeek": ["SATURDAY", "SUNDAY"],
  "leadTimeMin": 30,
  "leadTimeMax": 60,
  "isSpecialHour": false
} {
  "@type": "ServiceHours",
  "@id": "6479/takeout",
  "orderType": "ADVANCE",
  "serviceId": "10824/takeout",
  "operationHoursId": ["427/takeoutOh", "2652/takeoutOh"],
  "opens": "T09:00",
  "closes": "T21:00",
  "dayOfWeek": ["SATURDAY", "SUNDAY"],
  "advanceBookingRequirementMin": 30,
  "advanceBookingRequirementMax": 2880,
  "advanceBookingSlotInterval": "PT15M",
  "isSpecialHour": false
} {
  "@type": "ServiceHours",
  "@id": "3754/takeout",
  "orderType": "ASAP",
  "serviceId": "10824/takeout",
  "validFrom": "2019-12-24T00:00:00+10:00",
  "validThrough": "2019-12-24T23:59:59+10:00",
  "opens": "T09:00",
  "closes": "T16:00",
  "leadTimeMin": 30,
  "leadTimeMax": 60,
  "isSpecialHour": true
}

العطلات وساعات العمل الخاصة

يمكنك استخدام السمة isSpecialHour الخاصة بـ ServiceHours وOperationHours. لإلغاء ساعات الخدمة الحالية و/أو ساعات العمل. يتيح هذا النهج تحديد ساعات العمل العادية مرة واحدة، وتجاوزها بشكل انتقائي العطلات والأحداث الخاصة.

هناك فترتان زمنيتان منفصلتان يجب تحديدهما للخدمة طريقة التنفيذ: فترة الطلب (OperationHours، وتحدّد الوقت الذي يمكن للمستخدمين فيه تقديم طلب) وفترة توفّر الطلب (ServiceHours، وتحدّد الوقت الذي تلبية طلبك).

حالة الاستخدام أفضل ممارسة
حالة الاستخدام 1: مفتوح لطلبات اليوم نفسه ولكنّه مغلق للطلبات المتقدّمة طلب لتحديد التواريخ التي تكون فيها ساعات العمل الخاصة صالحة، استخدم السمتان validFrom وvalidThrough الكيانات ServiceHours وOperationHours (مع ضبط الخاصية isSpecialHour على "true").

JSON

يحدّد هذا المثال أنّ الخدمة متاحة لطلبات اليوم نفسه في يوم عيد الميلاد، ولكنه مغلق للطلبات التي تم تحديد موعدها مسبقًا لهذا اليوم. يقبل المطعم خدمات الاستلام في أقرب وقت ممكن ويقبل الطلبات المسبقة.

ساعات الاستلام المعتادة (بما في ذلك ساعات الطلبات وساعات الخدمة) تبدأ من من الساعة 9 صباحًا حتى الساعة 9 مساءً، وخلال عشية عيد الميلاد في عام 2017، يمكن استلام الطلب من الساعة 9 صباحًا إلى الساعة 4 بعد الظهر. يبلغ الحد الأدنى لوقت الانتظار في استلام الطلب ساعة واحدة، والحدّ الأقصى لوقت الانتظار هو 90 دقيقة. يمكن للمستخدمين تقديم الطلبات قبل يومين (2880 دقيقة). قبل 30 دقيقة من أي يوم، ولا يمكن تقديم طلب في المطعم المغلق أيام/ساعات (مثل يوم عيد الميلاد، و4 تموز (يوليو)، وبعد الساعة 4 عصرًا عشية عيد الميلاد). يمكن للمستخدمين تقديم طلبات الاستلام قبل تقديمهم فقط بزيادات مدتها 15 دقيقة. مثلاً، 2:00 بعد الظهر، 2:15 بعد الظهر، 2:30 بعد الظهر).

لا يتم فرض رسوم استلام على المستخدم. يدعم هذا المثال السيناريوهات التالية:

  • ويمكن للمستخدمين تقديم طلب في 25 كانون الأول (ديسمبر) لاستلامه في اليوم نفسه.
  • يمكن للمستخدمين تقديم طلب مسبق في 25 كانون الأول (ديسمبر) لاستلامه. الموعد المحدد في 27 ديسمبر.
  • لا يمكن للمستخدمين تقديم طلب مُسبق في 22 كانون الأول (ديسمبر) للتسليم. الموعد المحدد في 25 ديسمبر.
  • لا يمكن للمستخدمين تقديم طلب مُسبق أو طلب في أقرب وقت ممكن في 4 تموز (يوليو).
{
  "@type": "Service",
  "@id": "10824/takeout",
  "serviceType": "TAKEOUT",
  "menuId": "10824",
  "restaurantId": "10824"
} {
  "@type": "OperationHours",
  "@id": "427/takeoutOh",
  "serviceId": "10824/takeout",
  "opens": "T09:00",
  "closes": "T21:00"
} {
  "@type": "ServiceHours",
  "@id": "613741/takeout",
  "orderType": "ASAP",
  "serviceId": "10824/takeout",
  "opens": "T09:00",
  "closes": "T21:00",
  "isSpecialHour": false,
  "leadTimeMin": 60,
  "leadTimeMax": 90
} {
  "@type": "ServiceHours",
  "@id": "37/takeout",
  "orderType": "ASAP",
  "serviceId": "10824/takeout",
  "operationHoursId": "427/takeoutOh",
  "opens": "T09:00",
  "closes": "T16:00",
  "validFrom": "2017-12-24T00:00:00-07:00",
  "validThrough": "2017-12-24T23:59:59-07:00",
  "isSpecialHour": true,
  "leadTimeMin": 60,
  "leadTimeMax": 90
} {
  "@type": "ServiceHours",
  "@id": "358/takeout",
  "orderType": "ASAP",
  "serviceId": "10824/takeout",
  "operationHoursId": "427/takeoutOh",
  "opens": "T00:00",
  "closes": "T00:00",
  "validFrom": "2017-12-25T00:00:00-07:00",
  "validThrough": "2017-12-25T23:59:59-07:00",
  "isSpecialHour": true,
  "leadTimeMin": 60,
  "leadTimeMax": 90
} {
  "@type": "ServiceHours",
  "@id": "4356/takeout",
  "orderType": "ASAP",
  "serviceId": "10824/takeout",
  "operationHoursId": "427/takeoutOh",
  "opens": "T00:00",
  "closes": "T00:00",
  "validFrom": "2017-07-04T00:00:00-07:00",
  "validThrough": "2017-07-04T23:59:59-07:00",
  "isSpecialHour": true,
  "leadTimeMin": 60,
  "leadTimeMax": 90
} {
  "@type": "ServiceHours",
  "@id": "3654/takeout",
  "orderType": "ADVANCE",
  "serviceId": "10824/takeout",
  "opens": "T09:00",
  "closes": "T21:00",
  "isSpecialHour": false,
  "advanceBookingRequirementMin": 30,
  "advanceBookingRequirementMax": 2880,
  "advanceBookingSlotInterval": "PT15M"
} {
  "@type": "ServiceHours",
  "@id": "54/takeout",
  "orderType": "ADVANCE",
  "serviceId": "10824/takeout",
  "opens": "T00:00",
  "closes": "T00:00",
  "validFrom": "2017-12-24T00:00:00-07:00",
  "validThrough": "2017-12-24T23:59:59-07:00",
  "isSpecialHour": true,
  "advanceBookingRequirementMin": 30,
  "advanceBookingRequirementMax": 2880,
  "advanceBookingSlotInterval": "PT15M"
} {
  "@type": "ServiceHours",
  "@id": "5436/takeout",
  "orderType": "ADVANCE",
  "serviceId": "10824/takeout",
  "opens": "T00:00",
  "closes": "T00:00",
  "validFrom": "2017-12-25T00:00:00-07:00",
  "validThrough": "2017-12-25T23:59:59-07:00",
  "isSpecialHour": true,
  "advanceBookingRequirementMin": 30,
  "advanceBookingRequirementMax": 2880,
  "advanceBookingSlotInterval": "PT15M"
} {
  "@type": "ServiceHours",
  "@id": "345/takeout",
  "orderType": "ADVANCE",
  "serviceId": "10824/takeout",
  "opens": "T00:00",
  "closes": "T00:00",
  "validFrom": "2017-07-04T00:00:00-07:00",
  "validThrough": "2017-07-04T23:59:59-07:00",
  "isSpecialHour": true,
  "advanceBookingRequirementMin": 30,
  "advanceBookingRequirementMax": 2880,
  "advanceBookingSlotInterval": "PT15M"
}

رسوم التوصيل والاستلام

توضح الأمثلة أدناه كيفية تحديد رسوم التوصيل والاستلام خدمة ما.

حالة الاستخدام أفضل ممارسة
حالة الاستخدام 1: ضبط رسوم التسليم استخدام Fee لتحديد أنواع رسوم التسليم.
حالة الاستخدام 2: ضبط رسوم الخدمة لخدمات الاستلام استخدام Fee لتحديد أنواع رسوم خدمة الاستلام.

JSON

يتيح المطعم أنواعًا مختلفة من رسوم التوصيل.

في هذا المثال، هناك توصيل مجاني للطلبات التي لا تقل عن 30.00 دولارًا، رسوم تسليم ثابتة تبلغ 5.00 دولار أمريكي (أو ما يعادلها بالعملة المحلية) بدون حد أدنى للطلب، و3٪ من النسبة المئوية من إجمالي مبلغ سلة التسوق. ساعات التسليم (بما في ذلك كل من الطلب ساعات الخدمة) من 9 صباحًا إلى 11 مساءً. الحد الأدنى لوقت الانتظار للتسليم هو ساعة واحدة والحدّ الأقصى لوقت الانتظار هو 90 دقيقة.

يمكن للمستخدمين تقديم الطلبات قبل 6 أيام (8640 دقيقة) إلى 30 يومًا. دقائق مسبقًا لأي يوم. يمكن للمستخدمين تقديم طلبات التوصيل فقط في مقدّمًا بزيادات بمقدار 15 دقيقة (مثلاً 2:00 بعد الظهر أو 2:15 بعد الظهر أو 2:30 بعد الظهر) يتم تحديد المنطقة المؤهلة للتسليم في كيان ServiceArea.

{
  "@type": "Service",
  "@id": "10824/delivery",
  "serviceType": "DELIVERY",
  "menuId": "10824",
  "restaurantId": "10824"
} {
  "@type": "ServiceArea",
  "@id": "28427",
  "serviceId": "10824/delivery",
  "polygon": ["-20.728777 116.804256 -20.736323 116.8161 -20.722997 116.86468 -20.725406 116.871547 -20.736323 116.873607 -20.7474 116.816444 -20.756871 116.819877 -20.757673 116.788291 -20.740497 116.786403"]
} {
  "@type": "OperationHours",
  "@id": "427/deliveryOh",
  "serviceId": "10824/delivery",
  "opens": "T09:00",
  "closes": "T23:00"
} {
  "@type": "ServiceHours",
  "@id": "613741/delivery",
  "orderType": "ASAP",
  "serviceId": "10824/delivery",
  "opens": "T09:00",
  "closes": "T23:00",
  "isSpecialHour": false,
  "leadTimeMin": 60,
  "leadTimeMax": 90
} {
  "@type": "ServiceHours",
  "@id": "3654/delivery",
  "orderType": "ADVANCE",
  "serviceId": "10824/delivery",
  "opens": "T09:00",
  "closes": "T23:00",
  "isSpecialHour": false,
  "advanceBookingRequirementMin": 30,
  "advanceBookingRequirementMax": 8640,
  "advanceBookingSlotInterval": "PT15M"
} {
  "@type": "Fee",
  "@id": "28427",
  "serviceId": "10824/delivery",
  "feeType": "DELIVERY",
  "priceCurrency": "AUD",
  "price": 0.00,
  "eligibleTransactionVolumeMin": 30
} {
  "@type": "Fee",
  "@id": "4326",
  "serviceId": "10824/delivery",
  "feeType": "DELIVERY",
  "priceCurrency": "AUD",
  "price": 5.00,
  "eligibleTransactionVolumeMax": 29.99
} {
  "@type": "Fee",
  "@id": "5432",
  "serviceId": "10824/delivery",
  "feeType": "DELIVERY",
  "priceCurrency": "AUD",
  "percentageOfCart": 3.00
}

JSON

يتيح المطعم أنواعًا مختلفة من رسوم الخدمة.

في هذا المثال، هناك رسوم خدمة مجانية بحد أدنى 30.00 دولار للطلب، رسوم خدمة ثابتة تبلغ 1.00 دولار أمريكي (أو ما يعادلها بالعملة المحلية) بدون حد أدنى للطلب، و2% من رسوم الخدمة من إجمالي مبلغ سلة التسوق. ساعات الاستلام (بما في ذلك كلاً من الطلب والخدمة ساعات) هي من 9 صباحًا إلى 11 مساءً. يبلغ الحد الأدنى لوقت الانتظار في استلام الطلب ساعة واحدة. والحدّ الأقصى لوقت الانتظار هو 90 دقيقة.

يمكن للمستخدمين تقديم طلبات التسليم مقدّمًا بشكل مسبق فقط لمدة 15 دقيقة. (على سبيل المثال، 2:00 بعد الظهر أو 2:15 بعد الظهر أو 2:30 بعد الظهر).

{
  "@type": "Service",
  "@id": "10824/takeout",
  "serviceType": "TAKEOUT",
  "menuId": "10824",
  "restaurantId": "10824"
} {
  "@type": "OperationHours",
  "@id": "427/takeoutOh",
  "serviceId": "10824/takeout",
  "opens": "T09:00",
  "closes": "T23:00"
} {
  "@type": "ServiceHours",
  "@id": "613741/takeout",
  "orderType": "ASAP",
  "serviceId": "10824/takeout",
  "opens": "T09:00",
  "closes": "T23:00",
  "isSpecialHour": false,
  "leadTimeMin": 60,
  "leadTimeMax": 90
} {
  "@type": "ServiceHours",
  "@id": "3654/takeout",
  "orderType": "ADVANCE",
  "serviceId": "10824/takeout",
  "opens": "T09:00",
  "closes": "T23:00",
  "isSpecialHour": false,
  "advanceBookingRequirementMin": 30,
  "advanceBookingRequirementMax": 8640,
  "advanceBookingSlotInterval": "PT15M"
} {
  "@type": "Fee",
  "@id": "28427",
  "serviceId": "10824/takeout",
  "feeType": "SERVICE",
  "priceCurrency": "AUD",
  "price": 0.00,
  "percentageOfCart": 2.00,
  "eligibleTransactionVolumeMin": 30
} {
  "@type": "Fee",
  "@id": "4326",
  "serviceId": "10824/takeout",
  "feeType": "SERVICE",
  "priceCurrency": "AUD",
  "price": 1.00,
  "percentageOfCart": 2.00,
  "eligibleTransactionVolumeMax": 29.99
}

رسوم التوصيل الديناميكي

توضح الأمثلة أدناه كيفية تحديد رسوم خدمة التوصيل التي تعتمد على عوامل مختلفة، مثل المنطقة والوقت من اليوم وعدد العناصر.

حالة الاستخدام أفضل ممارسة
حالة الاستخدام 1: رسوم التسليم حسب المنطقة والمسافة استخدِم سمة eligibleRegion Fee لتحديد المنطقة وprice سمات priceCurrency لتحديد السعر.
حالة الاستخدام 2: رسوم التسليم حسب الوقت استخدام السمتَين validFrom وvalidThrough من Fee لتحديد الوقت الذي تكون فيه رسوم التسليم سارية.
حالة الاستخدام 3: عملية التسليم المجانية أعلاه ومبلغ الطلب يمكنك استخدام eligibleTransactionVolumeMin و eligibleTransactionVolumeMax من المواقع Fee لتحديد الحدّ الأدنى والأقصى لقيمة سلة التسوّق المرتبطة بوحدة التسليم السعر.

JSON

تتقاضى الخدمة النموذجية التالية رسوم تسليم قدرها 5.00 دولارات أمريكية (أو ما يعادلها بالعملة المحلية) في 94087 الرمز البريدي ورسوم بقيمة 2.00 دولار أمريكي للمناطق الأخرى.

{
  "@type": "Fee",
  "@id": "4326",
  "serviceId": "10824/delivery",
  "feeType": "DELIVERY",
  "priceCurrency": "USD",
  "price": 5.00,
  "eligibleRegion": "28427"
} {
  "@type": "ServiceArea",
  "@id": "28427",
  "serviceId": "10824/delivery",
  "postalCode": 94087,
  "addressCountry": "US"
} {
  "@type": "Fee",
  "@id": "5432",
  "serviceId": "10824/delivery",
  "feeType": "DELIVERY",
  "priceCurrency": "USD",
  "price": 2.00
}

JSON

تتقاضى الخدمة النموذجية التالية رسوم تسليم قدرها 20 دولارًا أمريكيًا (أو ما يعادلها بالعملة المحلية) اعتبارًا من كانون الثاني (يناير). 1 من 2017 إلى 1 شباط (فبراير) 2017، و10 دولارات في أي وقت آخر.

{
  "@type": "Fee",
  "@id": "4326",
  "serviceId": "10824/delivery",
  "feeType": "DELIVERY",
  "priceCurrency": "USD",
  "price": 10.00
} {
  "@type": "Fee",
  "@id": "5432",
  "serviceId": "10824/delivery",
  "feeType": "DELIVERY",
  "priceCurrency": "USD",
  "price": 20.00,
  "validFrom": "2017-01-01T00:00:00-07:00",
  "validThrough": "2017-02-01T00:00:00-07:00"
}

JSON

تفرض الخدمة التالية رسوم تسليم بقيمة 10 دولارات أمريكية (أو ما يعادلها بالعملة المحلية) للطلبات التي تصل قيمتها إلى 100 دولار، وبدون رسوم تسليم في الحالات الأخرى.

{
  "@type": "Fee",
  "@id": "4326",
  "serviceId": "10824/delivery",
  "feeType": "DELIVERY",
  "priceCurrency": "USD",
  "price": 10.00,
  "eligibleTransactionVolumeMax": 99.99
} {
  "@type": "Fee",
  "@id": "5432",
  "serviceId": "10824/delivery",
  "feeType": "DELIVERY",
  "priceCurrency": "USD",
  "price": 0.00,
  "eligibleTransactionVolumeMin": 100
}

مناطق خدمة التوصيل

توضح الأمثلة أدناه كيفية تحديد مناطق نطاق الخدمة المتاحة خدمة التوصيل.

حالة الاستخدام أفضل ممارسة
حالة الاستخدام 1: تعريف منطقة نطاق الخدمة

استخدام ServiceArea لتحديد المنطقة الجغرافية التي يمكن توصيل الطعام فيها.

حالة الاستخدام 2: لديك منطقة خدمة Polygon.
حالة الاستخدام 3: لديك منطقة نطاق خدمة واحدة، ولكنك لا تقدّم خدمة مساحة أصغر داخلها.
حالة الاستخدام 4: لديك عدة مناطق نطاق خدمة. إنشاء عدة ServiceArea والكيانات لتمثيل مناطق نطاق خدمتك.

JSON

يقدم المطعم خدمات التوصيل إلى مناطق نطاق خدمة مختلفة. تشير رسالة الأشكال البيانية يمكن تحديد مناطق نطاق الخدمة من خلال شكل مضلّع أو رمز بريدي أو دوائر.

{
  "@type": "Service",
  "@id": "10824/delivery",
  "serviceType": "DELIVERY",
  "menuId": "10824",
  "restaurantId": "10824"
} {
  "@type": "ServiceArea",
  "@id": "28427",
  "serviceId": "10824/delivery",
  "polygon": ["-20.728777 116.804256 -20.736323 116.8161 -20.722997 116.86468 -20.725406 116.871547 -20.736323 116.873607 -20.7474 116.816444 -20.756871 116.819877 -20.757673 116.788291 -20.740497 116.786403"]
} {
  "@type": "ServiceArea",
  "@id": "28427",
  "serviceId": "10824/delivery",
  "postalCode": 6714,
  "addressCountry": "AU"
} {
  "@type": "ServiceArea",
  "@id": "28427",
  "serviceId": "10824/delivery",
  "geoMidpointLatitude": -20.733575,
  "geoMidpointLongitude": 116.844931,
  "geoRadius": 1000
} {
  "@type": "OperationHours",
  "@id": "427/deliveryOh",
  "serviceId": "10824/delivery",
  "opens": "T09:00",
  "closes": "T23:00"
} {
  "@type": "ServiceHours",
  "@id": "613741/delivery",
  "orderType": "ASAP",
  "serviceId": "10824/delivery",
  "opens": "T09:00",
  "closes": "T23:00",
  "isSpecialHour": false,
  "leadTimeMin": 60,
  "leadTimeMax": 90
} {
  "@type": "ServiceHours",
  "@id": "3654/delivery",
  "orderType": "ADVANCE",
  "serviceId": "10824/delivery",
  "opens": "T09:00",
  "closes": "T23:00",
  "isSpecialHour": false,
  "advanceBookingRequirementMin": 30,
  "advanceBookingRequirementMax": 8640,
  "advanceBookingSlotInterval": "PT15M"
} {
  "@type": "Fee",
  "@id": "4326",
  "serviceId": "10824/delivery",
  "feeType": "DELIVERY",
  "priceCurrency": "AUD",
  "price": 5.00
}

JSON

{
  "@type": "ServiceArea",
  "@id": "28427",
  "serviceId": "10824/delivery",
  "polygon": ["37.806000 -122.425592 37.775849 -122.419043 37.795547 -122.394046 37.808747 -122.412619"]
}

JSON

مرر قائمة تحتوي على سلاسل تمثل حلقات المضلّع. تضمين مناطق مستبعَدة في السمة polygon ضمن ServiceArea تفسّر خدمة "طلب الطعام" المناطق المتداخلة على أنّها مناطق مستبعَدة.

{
  "@type": "ServiceArea",
  "@id": "28427",
  "serviceId": "10824/delivery",
  "polygon": ["37.771535 -122.506881 37.764289 -122.506669 37.766497 -122.453058", "37.791707 -122.447987 37.746676 -122.449433 37.736150 -122.505944 37.780924 -122.509729"]
}

JSON

{
  "@type": "ServiceArea",
  "@id": "28427",
  "serviceId": "10824/delivery",
  "polygon": ["37.785847 -122.484851 37.772757 -122.483983 37.774442 -122.458563 37.786876 -122.459474"]
} {
  "@type": "ServiceArea",
  "@id": "4356",
  "serviceId": "10824/delivery",
  "polygon": ["37.774804 -122.454774 37.766224 -122.452881 37.769087 -122.436043 37.773087 -122.437417"]
}

حذف الكيانات وإيقافها

يمكنك إزالة الكيانات من خدمتك إذا لم تعُد تريد من Google أن تفعلها عرضها للمستخدمين. يمكن الاستفادة من هذه العملية إذا كنت بحاجة إلى إعلام Google تم إغلاق المطعم أو الخدمة نهائيًا أو مؤقتًا.

إزالة الكيانات

لإزالة كيان، احذفه من خلاصاتك. اتفاقية مستوى الخدمة تبلغ ساعتَين. إلى إعادة تقديم الكيان، وإضافته مرة أخرى في خلاصاتك.

إزالة كيانات الخدمة مؤقتًا

يمكنك أيضًا إيقاف كيان Service مؤقتًا لأي من محددة أو فترة زمنية غير محددة.

من المفيد إيقاف واحدة لفترة زمنية محددة إذا كنت تريد تمكين المستخدمين تقديم الطلبات مقدمًا مع إيقاف الطلبات الفورية خلال فترة زمنية محددة فترة (على سبيل المثال، خلال عطلة).

في ما يلي إيقاف كيان Service لفترة زمنية غير محدّدة: مفيدًا إذا كنت تريد منع المستخدمين من تقديم كلا الطلبين مسبقًا للطلبات الفورية حتى تاريخ مستقبلي غير محدد.

يتضمن إيقاف الخدمة مؤقتًا تحديث ملفات الخلاصة مباشرةً أثناء بإزالة المحتوى بشكل نهائي.

يمكنك استخدام الأساليب أدناه لإيقاف ساعات العمل في Service أو إلغائها خلال فترة زمنية محدّدة مسبقًا.

  • تعليق كيان Service مؤقتًا لفترة محدّدة فترة زمنية معروفة مسبقًا (على سبيل المثال، ساعات العمل خلال العطلات) استخدام الكيانات OperationHours وServiceHours.

    أنشئ كيان ServiceHours جديدًا باستخدام السمة isSpecialHour إلى true. يجب توفير السمتَين validFrom وvalidThrough لتحديد قيم الوقت عندما تكون ساعات العمل الخاصة صالحة. يُرجى ضبط opens وcloses مرة على "00:00". سيتم استئناف الخدمة تلقائيًا بعد ساعات العمل من كيان ServiceHours لساعات العمل العادية مرة واحدة خارج قيمتَي validFrom وvalidThrough لكيان ساعات العمل الخاصة.

    {
      "@type":"ServiceHours",
      "@id":"delivery_1_service_hours_holiday",
      "orderType":"ASAP",
      "serviceId":"delivery_1",
      "operationHoursId":"delivery_1_op_hours",
      "opens":"00:00",
      "closes":"00:00",
      "validFrom":"2022-12-25T00:00:00-05:00",
      "validThrough":"2022-12-26T00:00:00-05:00",
      "leadTimeMin":"20",
      "leadTimeMax":"20",
      "isSpecialHour":true
    }
    
  • إزالة كيان Service مؤقتًا لفترة غير محددة نقطة، اضبط خاصية isDisabled على "true". لإعادة تفعيلها، يجب إزالة من الكيان أو اضبط القيمة على "false".

    يجب عدم استخدام السمة isDisabled إلا إذا كنت لا تعرف ذلك ومتى ستتم إعادة إنشاء الخدمة. على سبيل المثال، يمكنك استخدامها لعرض غير متوقَّع الأحداث ولا تستخدمه للعطلات).