has added a CSV format promotions file when running --promos. Item.py was added for moduling.

This commit is contained in:
KorenLazar
2021-01-28 16:25:38 +02:00
parent 47c0d04ce4
commit d7e5b709f8
8 changed files with 94 additions and 29 deletions

13
item.py Normal file
View File

@@ -0,0 +1,13 @@
class Item:
"""
A class representing a product in some supermarket.
"""
def __init__(self, name: str, price: float, manufacturer: str, code: int):
self.name: str = name
self.price: float = price
self.manufacturer: str = manufacturer
self.code: int = code
def __repr__(self):
return str((self.name, self.price, self.manufacturer, self.code))