Hacktoberfest 2026: những issue maintainer đã đánh dấu cho tháng Mười, đang mở và phù hợp người mới. Xem issue Hacktoberfest

code a python app will be used to make reservations to the restaurant

Đang mở
#84 0 bình luận 4 reaction 0 người được giao Xem trên GitHub

Chưa có ai nhận issue này.

Đánh giá

Độ khó
5/5
Thời gian dự kiến
Hơn một tuần
Mức phù hợp với người mới
20/100
Loại issue
Tính năng
Độ rõ ràng
Cần làm rõ
Mức độ hoạt động
Đình trệ
Công nghệ
python
Lĩnh vực
backend, database

Hướng nghiên cứu

Start by reviewing the proposed restaurant-reservation use cases, entities, UI flows, and database fields in the issue. No implementation files, entry points, or tests are named, and the issue does not define a bounded first milestone or concrete completion criteria.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

For this application first we have to identify the data that needs to be saved and accessed, with that we will churn out entities that will take form of classes and use inheritance in case of relationship. After that based on the use cases we can design functions and events flow.

so here if we see the requirement defined for application :

  1. There are customers who make reservation

  2. There are tables for which reservation are made.

  3. Waiters who will take orders.

  4. Food Item that will be added to bill

  5. Bill which has to be payed.

  6. Order which contain list of food items ordered with quantity

So five entities i.e. classes needs to be created.

Now, since customer and waiter are person so we can create an abstract class with some common attribute like name, ssn, phone number, address e.t.c. and then we can inherit it to make customer and waiter class with their specific attribute like waiter id for waiter and no. of accompaniment for customer.

Similarly food item can be an interface which can be inherited in veg and non veg abstract classes which can further inherited in different food items available in restaurant.

Now, for holding reservation details we need to create a reservation table in db which contains details like :

1.reservation id

2.table num

3.customer id

4.waiter id

5.date and time

6.order

7.bill

Now, below are the possible use cases that I can sort out :

  1. Make Reservation - For this use case from ui user will fill the details like time and no. of people for dinner reservation, based on that we will search in db for the availability of table with that capacity on that time. For this db query we can use table and reservation. If available, then we will send success response with table id to ui and then user can continue after filling his details like name, ssn e.t.c. and make reservation with confirmation button. With this we can generate a reservation num and save the details in that table with a waiter alloted to that.

  2. Waiter login - this is simple login flow so nothing new here.

  3. Waiter access to add order - Here at his home page waiter can select table (in case assigned to multiple table) for which he has to add order. Here on the ui we has to provide a search functionality

a) to search food items - so an event is made on click of search button which will call find query in food item db and return result. This result can be used by waiter and then click on add button after selecting quantity, we have

b) create an event to generate order or update order with those food item.

  1. Bill generation - When dinner is done then waiter can click on checkout button and then need to create an event which will create bill based on the order of that table and save it in database with waiter tip details :)

I have not created any class and function as based on programming language it changes but design will remain the same.

Now for error handling-

There can be multiple error as table not available, food item out of stock, total calculation at the time of bill generation and many other with technical errors like db query, logical errors.

Also , ui related errors like phone number not correct, ssn not provided e.t.c.

Ngôn ngữ chính
Không có dữ liệu ngôn ngữ
Star
29.7k
Fork
7k
Chỉ số merge pull request
Không có pull request nào được merge trong 30 ngày

Chuẩn bị môi trường

Dự án này không cung cấp dev container, Dockerfile hay hướng dẫn đóng góp, nên bạn cần tự thiết lập môi trường: hãy bắt đầu từ README và xem hướng dẫn đóng góp lần đầu của chúng tôi để biết các bước chung.

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của zhiwehu/Python-programming-exercises

Tất cả issue của zhiwehu/Python-programming-exercises

Issue tương tự

Thêm issue về Backend & API Design

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.