docs + locations

This commit is contained in:
JMARyA 2024-09-02 18:40:02 +02:00
parent e1618b40ef
commit 48f00d8f6f
Signed by: jmarya
GPG key ID: 901B2ADDF27C2263
17 changed files with 390 additions and 33 deletions

View file

@ -142,8 +142,13 @@ impl Variant {
/// # Returns
///
/// Returns a UUID string representing the transaction.
pub async fn supply(&self, price: Price, origin: Option<&str>) -> String {
let t = Transaction::new(&self.item, &self.variant, price, origin);
pub async fn supply(
&self,
price: Price,
origin: Option<&str>,
location: Option<&str>,
) -> String {
let t = Transaction::new(&self.item, &self.variant, price, origin, location).await;
t.insert().await.unwrap();