-
Notifications
You must be signed in to change notification settings - Fork 6
/
menu.py
50 lines (40 loc) · 1.5 KB
/
menu.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
################################################
# menu.py #
# Defines menu options offered to the customer.#
# #
################################################
################################################
# json #
# Standard library methods for processing JSON #
# requests and responses. #
# #
################################################
import json
def getMenuStarters():
response = {"options": [
{"name": "Chicken Wings", "price": 1895},
{"name": "Lamb Samosas", "price": 1295},
{"name": "Onion Rings", "price": 1495}]
}
return json.dumps(response)
def getMenuMainCourses():
response = {"options": [
{"name": "BaconBurguer", "price": 2590},
{"name": "Cesar Salad", "price": 2290},
{"name": "Fish & Chips", "price": 2355}]
}
return json.dumps(response)
def getMenuDesserts():
response = {"options": [
{"name": "Ice Cream", "price": 1295},
{"name": "Tiramisú", "price": 1495},
{"name": "Brownie", "price": 1590}]
}
return json.dumps(response)
def getMenuDrinks():
response = {"options": [
{"name": "Bottled water", "price": 595},
{"name": "Coke", "price": 795},
{"name": "Blood", "price": 19995}]
}
return json.dumps(response)