Skip to main content

Core business logic for car dealership: order splitting, preorder calculation, sales reporting and top sales

Project description

autodealer-core

Core business logic for a car dealership management system.

Features

  • calculate_sale_items – split order into in‑stock and preorder parts.
  • total_amount – compute total price.
  • aggregate_report – group sales by car model and sort by revenue.
  • top_sales – get top N cars by quantity sold.

Installation

pip install autodealer-core

Usage

from autodealer_core import calculate_sale_items, total_amount

cart_totals = {1: 5, 2: 2} stock_map = {1: (3, 100), 2: (10, 200)} items = calculate_sale_items(cart_totals, stock_map) total = total_amount(items) print(total) # 900

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

autodealer_core-0.1.7.tar.gz (3.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

autodealer_core-0.1.7-py3-none-any.whl (4.2 kB view details)

Uploaded Python 3

File details

Details for the file autodealer_core-0.1.7.tar.gz.

File metadata

  • Download URL: autodealer_core-0.1.7.tar.gz
  • Upload date:
  • Size: 3.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.0

File hashes

Hashes for autodealer_core-0.1.7.tar.gz
Algorithm Hash digest
SHA256 b57ed80c28334e7cd266b80dd4c642e270d1f782feba5397fdbca2a5bb36c303
MD5 98717af9fffbe6620c530896456a4f87
BLAKE2b-256 efb7c28a62faeefb8c0d3818d2f2b427ed4b47a1925a7ccdaa4ec7586c1ccfd6

See more details on using hashes here.

File details

Details for the file autodealer_core-0.1.7-py3-none-any.whl.

File metadata

File hashes

Hashes for autodealer_core-0.1.7-py3-none-any.whl
Algorithm Hash digest
SHA256 72bb59452b38b147200b1159415f60dd4400d9ec72abf16aebea95fc03b05109
MD5 58e79d12fb17a0d4ae28cee7d98a96cc
BLAKE2b-256 08ed0893e001af9209b7b94b921c951cc5a99d29557b0f715b4165f763802044

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page