|
@@ -33,6 +33,10 @@ def calculate_estimated_price(material_id: int, file_sizes: List[int], file_quan
|
|
|
discount_percent = min((total_qty - 1) * 0.05, 0.20)
|
|
discount_percent = min((total_qty - 1) * 0.05, 0.20)
|
|
|
discount_multiplier = 1.0 - discount_percent
|
|
discount_multiplier = 1.0 - discount_percent
|
|
|
|
|
|
|
|
|
|
+ estimated_total = 0.0
|
|
|
|
|
+ file_costs = []
|
|
|
|
|
+ base_fee = 5.0 # Minimum setup fee per file
|
|
|
|
|
+
|
|
|
for size, qty in zip(file_sizes, file_quantities):
|
|
for size, qty in zip(file_sizes, file_quantities):
|
|
|
total_size_mb = size / (1024 * 1024)
|
|
total_size_mb = size / (1024 * 1024)
|
|
|
# Empirical conversion: ~8cm3 per 1MB of STL (binary)
|
|
# Empirical conversion: ~8cm3 per 1MB of STL (binary)
|