Project files/LaptopInventory(1).csv 2347800,Apple ,999,7/3/2020, 2390112,Dell,799,7/2/2020, 7346234,Lenovo,239,9/1/2020,damaged __MACOSX/Project files/._LaptopInventory(1).csv Project...

1 answer below »
I just need help with my homework, I don't even know where to start.


Project files/LaptopInventory(1).csv 2347800,Apple ,999,7/3/2020, 2390112,Dell,799,7/2/2020, 7346234,Lenovo,239,9/1/2020,damaged __MACOSX/Project files/._LaptopInventory(1).csv Project files/ManufacturerList(1).csv 1167234,Apple ,phone, 2390112,Dell,laptop, 9034210,Dell,tower, 7346234,Lenovo,laptop,damaged 3001265,Samsung,phone, 2347800,Apple ,laptop, 1009453,Lenovo,tower, __MACOSX/Project files/._ManufacturerList(1).csv Project files/FullInventory(1).csv 2347800,Apple ,laptop,999,7/3/2020, 1167234,Apple ,phone,534,2/1/2021, 2390112,Dell,laptop,799,7/2/2020, 9034210,Dell,tower,345,5/27/2020, 7346234,Lenovo,laptop,239,9/1/2020,damaged 1009453,Lenovo,tower,599,10/1/2020, 3001265,Samsung,phone,1200,12/1/2023, __MACOSX/Project files/._FullInventory(1).csv Project files/DamagedInventory(1).csv 7346234,Lenovo,laptop,239,9/1/2020 __MACOSX/Project files/._DamagedInventory(1).csv Project files/ServiceDatesList(1).csv 9034210,5/27/2020 2390112,7/2/2020 2347800,7/3/2020 7346234,9/1/2021 1009453,10/1/2021 1167234,2/1/2022 3001265,12/1/2023 __MACOSX/Project files/._ServiceDatesList(1).csv Project files/PastServiceDateInventory(1).csv 9034210,Dell,tower,345,5/27/2020 __MACOSX/Project files/._PastServiceDateInventory(1).csv Project files/PriceList(1).csv 3001265,1200 2347800,999 2390112,799 1009453,599 1167234,534 9034210,345 7346234,239 __MACOSX/Project files/._PriceList(1).csv Microsoft Word - CIS2348_FinalProjectPart1.docx CIS 2348, Spring 2021 Final Project Part 1 You will design a program that manages the inventory of an electronics store. You will need to use a number of concepts that you learned in class including: use of classes, use of dictionaries and input and output of comma delimeted csv files. Input: a) ManufacturerList.csv -- contains items listed by row. Each row contains item ID, manufacturer name, item type, and optionally a damaged indicator b) PriceList.csv -- contains items listed by row. Each row contains item ID and the item price. c) ServiceDatesList.csv – contains items listed by row. Each row contains item ID and service date. Example ManufacturerList.csv, PriceList.csv and ServiceDatesList.csv are provided for reference. Your code will be expected to work with any group input files of the appropriate format. Manufacturers can and will likely be different as will the actual items. Required Output: Processed Inventory Reports: a. FullInventory.csv -- all the items listed by row with all their information . The items should be sorted alphabetically by manufacturer. Each row should contain item ID, manufacturer name, item type, price, service date, and list if it is damaged. The item attributes must appear in this order. b. Item type Inventory list, i.e LaptopInventory.csv -- there should be a file for each item type and the item type needs to be in the file name. Each row of the file should contain item ID, manufacturer name, price, service date, and list if it is damaged. The items should be sorted by their item ID. c. PastServiceDateInventory.csv – all the items that are past the service date on the day the program is actually executed. Each row should contain: item ID, manufacturer name, item type, price, service date, and list if it is damaged. The items must appear in the order of service date from oldest to most recent. d. DamagedInventory.csv –all items that are damaged. Each row should contain : item ID, manufacturer name, item type, price, and service date. The items must appear in the order of most expensive to least expensive. Commit all your .py files on Github. Provide a link on BlackBoard. Put all your files in a folder named “FinalProjectPart1” and name your files with the starting phrase “FinalProject” for example FinalProjectInput.py Comment your code extensively. Include comment block with your name and student ID at the top of every .py file.
Answered Same DayJun 30, 2021

Answer To: Project files/LaptopInventory(1).csv 2347800,Apple ,999,7/3/2020, 2390112,Dell,799,7/2/2020,...

Pratap answered on Jul 01 2021
146 Votes
"""
Start Program
"""
# import libraries
import datetime
class Manufacturer:
"""
Create class for manufacturer details
"""
# class constructor
def __init__(self, item_id, name, item_type, condition):
self.item_id = item_id
self.name = name
self.item_type = item_type
self.condition = condition
def __str__(self):
# return type string for the class
return str(self.item_id) + "," + self.name + "," + self.item_type + "," + self.condition
def __eq__(self, other):
# uniquify all instances
if isinstance(other, Manufacturer):
return other.item_id == self.item_id and other.name == self.name \
and other.type == self.item_type and other.condition == self.condition
class Price:
"""
Define a class for prices of the items
"""
# class constructor
def __init__(self, item_id, price, items):
self.item_id = item_id
self.price = price
self.name = None
self.item_type = None
self.condition = None
self.match_data(items)
# create a function to match pre-loaded data
def match_data(self, items):
for i in items:
if i.item_id == self.item_id:
self.name = i.name
self.item_type = i.item_type
self.condition = i.condition
def __str__(self):
return str(self.item_id) + "," + self.name + "," + self.item_type + "," + self.condition + "," + str(self.price)
class ServiceDates:
"""
Create a class for service dates of the items
"""
# constructor
def __init__(self, item_id, date, items):
self.item_id = item_id
self.date = date
self.name = None
self.item_type = None
self.condition = None
self.price = None
self.match_data(items)
# create a function to match the pre-loaded data
def match_data(self, items):
for i in items:
if i.item_id == self.item_id:
self.name = i.name
self.item_type = i.item_type
self.condition = i.condition
self.price = i.price
# define class objects as strings
def __repr__(self):
if self.condition:
...
SOLUTION.PDF

Answer To This Question Is Available To Download

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here