Point of Sale
- This will be very basic version of point of sale
- We will have two options
- We will not be storing any thing permanently
- Topics:
- datatypes
- loops
- conditional statements
- functions
- list and dictionary comprehensions
Creating a new python project
- Create a new folder
lt_pos
- cd in to the folder and create two files
Readme.md and main.py
- Refer Here for markdown
Basic Menu to the user
- The Application when execute will give basic menu
===== LT POS =====
1. Sale
2. Inventory
3. Exit
Select an option:
Support inventory
- Our inventory item will be identified by a unique id and for every item we will have
- id
- name
- description
- price
- A sample item
{
"id": "1",
"name": "Ambika Darbar Agarbathi",
"description": "",
"price": 25,
"quantity": 100
}
- An item is a dictionary and since we have mulitple items in inventory, inventory will be list of dictionaries
- Refer Here for inventory changes
- Exercise: try implementing delete_item
Like this:
Like Loading...