Restaurant Management System V-3 ( Invoice Generation )


Restaurant Management V-2 with invoice generation



Tkinter Storing product sale with details in table and generate Invoice Restaurant Management system


The Part -3 of the script should have these added features

Once the details of selection of product with total and tax details are shown ( Check the Part II of Restaurant Management ) the following features are to be added.
  1. On click of the Reset / confirmation button the display part will reset to blank ( listing of sold products ) and all the spinboxes will reset to 0.
  2. As the sale is confirmed, one unique bill number is to be generated by inserting data , total price and tax price to the plus2_bill table.
  3. Using the unique bill number , all sold product details like product id, quantity , price with bill number and data are to be inserted to plus2_sell table.
  4. One button will be displayed saying Generate bill and on click of it the function my_invoice() will be triggered.
  5. The function my_invoice will receive the bill number and using this it will generate the Invoice.
  6. The function my_invoice will collect all the names of the product sold, with price, quantity and generate the full invoice.
main-db-3.py


my_connect.py
from sqlalchemy import create_engine
my_conn = create_engine("mysql+mysqldb://root:pw@localhost/db_name")
MySQL Installing
MySQL Connecting string
MySQL connection using SQLAlchemy

my_invoice.py


Create table plus2_bill, plus2_sell and to create product table plus2_products and to insert sample data, use this sql dump.

config.py
path_image="G:\\My Drive\\testing\\plus2_restaurant_v1\\images\\"
font1=('Times',14,'normal')
font2=('Times',32,'bold')

Adding sample data to tables

Here is the script to first remove all records from plus2_bill and plus2_sell, then insert records for previous n ( check the for loop at the end ) days. No data is added to plus2_products table.

my_insert.py
Restaurant Management V-1 Restaurant Management V-2 Creating Tables
More Projects using Tkinter
Subhendu Mohapatra — author at plus2net
Subhendu Mohapatra

Author

🎥 Join me live on YouTube

Passionate about coding and teaching, I publish practical tutorials on PHP, Python, JavaScript, SQL, and web development. My goal is to make learning simple, engaging, and project‑oriented with real examples and source code.



Subscribe to our YouTube Channel here



plus2net.com







Python Video Tutorials
Python SQLite Video Tutorials
Python MySQL Video Tutorials
Python Tkinter Video Tutorials
We use cookies to improve your browsing experience. . Learn more
HTML MySQL PHP JavaScript ASP Photoshop Articles Contact us
©2000-2025   plus2net.com   All rights reserved worldwide Privacy Policy Disclaimer