{% extends "core/base.html" %} {% load static %} {% block title %}Stock Forecast - SwiftPOS{% endblock %} {% block topbar_title %}Stock Forecast{% endblock %} {% block content %}
Predicted stock exhaustion based on the last 30 days of sales velocity.
| Product | Current Stock | Avg Daily Sales | Days Until Stockout | Restock Qty | Health |
|---|---|---|---|---|---|
|
{{ fc.product.name }}
{{ fc.product.sku }}
|
{{ fc.product.stock_quantity }} | {{ fc.avg_daily_sales|floatformat:1 }} | {% if fc.days_until_stockout is not None %} {{ fc.days_until_stockout }} day{{ fc.days_until_stockout|pluralize }} {% else %} No recent sales {% endif %} | {% if fc.recommended_restock_qty > 0 %} {{ fc.recommended_restock_qty }} units {% else %} — {% endif %} | {% if fc.stock_health == 'critical' %} 🔴 Critical {% elif fc.stock_health == 'low_risk' %} 🟡 Low Risk {% elif fc.stock_health == 'dead' %} 💀 Dead Stock {% elif fc.stock_health == 'overstock' %} 📦 Overstock {% else %} ✅ Healthy {% endif %} |
No forecast data yet. Run python manage.py generate_insights to generate forecasts.