From 06b7741015715efc7c001a95d3465224ec516d1a Mon Sep 17 00:00:00 2001 From: Reckless_Satoshi Date: Wed, 16 Feb 2022 14:09:40 -0800 Subject: [PATCH] Fix minimum value, adjust decimal places and digits for BTC scales --- api/models.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/api/models.py b/api/models.py index bcf9fb4c..21766374 100644 --- a/api/models.py +++ b/api/models.py @@ -132,7 +132,7 @@ class Order(models.Model): # order details type = models.PositiveSmallIntegerField(choices=Types.choices, null=False) currency = models.ForeignKey(Currency, null=True, on_delete=models.SET_NULL) - amount = models.DecimalField(max_digits=9, decimal_places=4, validators=[MinValueValidator(0.00001)]) + amount = models.DecimalField(max_digits=16, decimal_places=8, validators=[MinValueValidator(0.00000001)]) payment_method = models.CharField(max_length=35, null=False, default="not specified", blank=True) # order pricing method. A explicit amount of sats, or a relative premium above/below market.