Skip to content

Sample State

dch21 edited this page Nov 7, 2020 · 12 revisions
{
  entities: {
    restaurants: {
      1: {
        address: "454 Van Brunt St, Brooklyn, NY 11231",
        capacity: 35,
        cuisine: "BBQ",
        description: "Texas style smokehouse serving BBQ brisket, ribs, sausages, pulled pork and other meats in a rusting dining hall.",
        dining_style: "Casual",
        dress_code: "Casual",
        hours: "Tue-Sun: 12:00 pm - 8:00 pm",
        id: 1,
        lat: 40.67507,
        lng: -74.016116,
        name: "Hometown Bar-B-Que",
        neighborhood: "Red Hook",
        parking_details: "Street",
        payment: "Cash, AMEX, VISA, MASTERCARD",
        phone_num: "347-294-4644",
        price_range: "$10-$25",
        public_transit: "B61",
        website: "https://hometownbbq.com/",
      },
    },
    users: {
      2: {
        email: "mc@test.com",
        first_name: "Mitch",
        id: 2,
        last_name: "Cummings",
       location: "Brooklyn"
      }
      16: {
        email: "bb@test.com",
        first_name: "Buckie",
        id: 16,
        last_name: "Beeves",
       location: "Manhattan"       
      },
    },
    reviews: {
      1: {
        id: 1,
        reviewText: "Good value, nice outdoors options",
        foodRating: 4,
        serviceRating: 4,
        ambienceRating: 4,
        noiseLevel: 2
        overallRating: 4,
        reviewerId: 7,
        restaurantId: 1,
        createdAt: Fri, 18 Sep 2020 00:25:11
      }
    },
    reservations: {
      5: {
        id: 5,
        notes: "",
        time: "7:00PM",
        email: "demo@gmail.com",
        phone-number: "555-555-5555",
        partySize: 1,
        userId: 1,
        restaurantId: 1
      }
    },
    searchResults: { 
      1: {...}, 
      2: {...}, 
      3: {...}
      }
    },
    aggregates: [3, "4.3", "4.7", "3.0", "3.3", "2.3", 1, 2, 0, 0, 0, 0]
  },
  ui: {
    modal: null, 
    filters: {price:[], boro: [], cuisine: []}
    }
  errors: {
    login: ["Incorrect username/password combination"],
    reservation: ["Must include time of reservation", "Must indicate party size"]
  },
  session: { currentUserId: 1 }
}

Clone this wiki locally