// rocie - An enterprise grocery management system - Web app // // Copyright (C) 2026 Benedikt Peetz // SPDX-License-Identifier: GPL-3.0-or-later // // This file is part of Rocie. // // You should have received a copy of the License along with this program. // If not, see . use leptos::{IntoView, component, view}; use crate::{ api::products_registered_wrapped, components::{async_fetch::AsyncFetch, container::Container, icon_p::IconP}, }; #[component] pub fn ProductOverview() -> impl IntoView { view! { }, "products"), ( view! { }, "create-product", ), ( view! { }, "associate-barcode-product", ), ] > { AsyncFetch! { @map_error_in_producer fetcher = products_registered_wrapped(), producer = |products| { view! {

{format!("You have {} products.", products.len())}

} } } }
} }