From fa9f3940704777d681f2bd56e4e18e62f3257746 Mon Sep 17 00:00:00 2001 From: JMARyA Date: Fri, 3 May 2024 10:34:09 +0200 Subject: [PATCH] doc --- src/item.rs | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/src/item.rs b/src/item.rs index 3b074ad..15c0deb 100644 --- a/src/item.rs +++ b/src/item.rs @@ -365,10 +365,17 @@ impl Variant { todo!() } - // case: import - // made / bought an item -> supply - // check in with attrs -> uuid (transaction) - // commited to db + /// Records a supply transaction in the database. + /// + /// # Arguments + /// + /// * `amount` - The quantity of items supplied. + /// * `price` - The price of the supplied items. + /// * `origin` - The origin or source of the supplied items. + /// + /// # Returns + /// + /// Returns a UUID string representing the transaction. pub async fn supply(&self, amount: usize, price: Price, origin: &str) -> String { let db = get_mongo!();