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.8.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.8-py3-none-any.whl (4.2 kB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: autodealer_core-0.1.8.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.8.tar.gz
Algorithm Hash digest
SHA256 1bf47a494a92f63a173fc397bfcc6a6b5cb0ada74d0194a89a079ed22ac2a7f5
MD5 f3e847e286aaf40bcaf9d03ed47ea77c
BLAKE2b-256 fdd34c1d3980f63a8c562294cf4260a7b1cd5dd3469aeb81079ceee9eaf4db52

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for autodealer_core-0.1.8-py3-none-any.whl
Algorithm Hash digest
SHA256 1df4ffa1640f1d546e66df07c24af13f7a46ea0576876fd6bc10aa20ef45a58d
MD5 a4ffbc187488d7738d2ff107467b514b
BLAKE2b-256 fa300ad1c7c158277f668e0ae266dd06ca89d44206d1e6c81028a5325c73cb8f

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