Advertisement
Guest User

Untitled

a guest
Mar 28th, 2020
96
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.92 KB | None | 0 0
  1. class Merchandiser:
  2.     def __init__(self, name):
  3.         self.name = name
  4.  
  5.  
  6. class Client:
  7.     def __init__(self, name, email, phone, country, city, address):
  8.         self.name = name
  9.         self.email = email
  10.         self.phone = phone
  11.         self.country = country
  12.         self.city = city
  13.         self.address = address
  14.  
  15.  
  16. class Product:
  17.     def __init__(self, name, price, size, color):
  18.         self.name = name
  19.         self.price = price
  20.         self.size = size
  21.         self.color = color
  22.  
  23.  
  24. class Order:
  25.     def __init__(self, status, client, payment_type, payment_status):
  26.         self.status = status
  27.         self.client = client
  28.         self.payment_type = payment_type
  29.         self.payment_status = payment_status
  30.         self.products = []
  31.  
  32.     def add_product(self, product, quantity):
  33.         self.products.append({"product": product, "quantity": quantity, "amount": product.price * quantity})
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement