New Year revamp #40

Merged
FrederikBaerentsen merged 31 commits from gregoo/BrickTracker:master into master 2025-01-19 08:19:01 +01:00
Showing only changes of commit 463e00f3fe - Show all commits

View File

@ -5,11 +5,11 @@ SUM(IFNULL(missing.quantity, 0)) AS total_missing,
{% endblock %} {% endblock %}
{% block total_quantity %} {% block total_quantity %}
SUM(IFNULL((NOT inventory.is_spare) * inventory.quantity, 0)) AS total_quantity, SUM((NOT inventory.is_spare) * inventory.quantity * IFNULL(minifigures.quantity, 1)) AS total_quantity,
{% endblock %} {% endblock %}
{% block total_spare %} {% block total_spare %}
SUM(IFNULL(inventory.is_spare * inventory.quantity, 0)) AS total_spare, SUM(inventory.is_spare * inventory.quantity * IFNULL(minifigures.quantity, 1)) AS total_spare,
{% endblock %} {% endblock %}
{% block join %} {% block join %}
@ -20,6 +20,10 @@ AND inventory.part_num IS NOT DISTINCT FROM missing.part_num
AND inventory.color_id IS NOT DISTINCT FROM missing.color_id AND inventory.color_id IS NOT DISTINCT FROM missing.color_id
AND inventory.element_id IS NOT DISTINCT FROM missing.element_id AND inventory.element_id IS NOT DISTINCT FROM missing.element_id
AND inventory.u_id IS NOT DISTINCT FROM missing.u_id AND inventory.u_id IS NOT DISTINCT FROM missing.u_id
LEFT JOIN minifigures
ON inventory.set_num IS NOT DISTINCT FROM minifigures.fig_num
AND inventory.u_id IS NOT DISTINCT FROM minifigures.u_id
{% endblock %} {% endblock %}
{% block where %} {% block where %}