fix(elixir): improve storage location UI

- modify UI and UX to match categories system
This commit is contained in:
Schuwi
2025-09-14 16:03:56 +02:00
parent 4f1b273793
commit 1b498d286d
4 changed files with 506 additions and 401 deletions

View File

@@ -348,6 +348,15 @@ defmodule ComponentsElixir.Inventory do
|> Repo.aggregate(:count, :id)
end
@doc """
Counts components in a specific storage location.
"""
def count_components_in_storage_location(storage_location_id) do
Component
|> where([c], c.storage_location_id == ^storage_location_id)
|> Repo.aggregate(:count, :id)
end
@doc """
Increment component stock count.
"""