forked from taiansu/astro_04_js
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathhotel.js
51 lines (45 loc) · 987 Bytes
/
hotel.js
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
51
let hotel = {
name: "happy hotel",
address: "XXXXXXXXX",
tel: 1336783423,
stars: 5, //暫定
site: "www.happy.com.tw",
rooms: [
{roomNumber: 102, type: 'busniess', basePrice: 6000, wifi: false},
{roomNumber: 202, type: 'luxury', basePrice: 10000, wifi: true},
{},
{},
],
// room: {
// type: [{ business: 6000 }, { casual: 8000 }, { luxury: 10000 }],
// smoke: Boolean,
// meal: Boolean
// },
"swimming_pool": {},
"parking": {},
"gym": {},
"restaurant": {},
"staffs": {
managers: [],
part_times: [],
regular_stuffs: [],
},
"staffs2": [
{name: 'a', type: 'manager'},
{name: 'b', type: 'part-time'},
{name: 'c', type: 'regular'},
]
// {
// name: String,
// age: Integer,
// gender: String,
// language: ["English", "Chinese", "Japanese", "Korean"]
// }
}
function getHotelContact(hotel) {
return {
name: hotel.name,
tel: hotel.tel,
address: hotel.address
}
}