From 41d3acb8e87c6f58420cc4fbef114bb802a7ad85 Mon Sep 17 00:00:00 2001 From: cryptosharks131 Date: Sat, 22 Jan 2022 10:56:36 -0500 Subject: [PATCH] Fix issue, default AR values not being applied to new channels --- gui/migrations/0019_auto_20220122_1009.py | 23 +++++++++++++++++++++++ gui/models.py | 4 ++-- 2 files changed, 25 insertions(+), 2 deletions(-) create mode 100644 gui/migrations/0019_auto_20220122_1009.py diff --git a/gui/migrations/0019_auto_20220122_1009.py b/gui/migrations/0019_auto_20220122_1009.py new file mode 100644 index 00000000..af392808 --- /dev/null +++ b/gui/migrations/0019_auto_20220122_1009.py @@ -0,0 +1,23 @@ +# Generated by Django 3.2.7 on 2022-01-22 10:09 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('gui', '0018_auto_20220114_2218'), + ] + + operations = [ + migrations.AlterField( + model_name='channels', + name='ar_amt_target', + field=models.BigIntegerField(), + ), + migrations.AlterField( + model_name='channels', + name='ar_out_target', + field=models.IntegerField(), + ), + ] diff --git a/gui/models.py b/gui/models.py index 80df78d8..db489a57 100644 --- a/gui/models.py +++ b/gui/models.py @@ -79,9 +79,9 @@ class Channels(models.Model): is_active = models.BooleanField() is_open = models.BooleanField() auto_rebalance = models.BooleanField(default=False) - ar_amt_target = models.BigIntegerField(default=100000) + ar_amt_target = models.BigIntegerField() ar_in_target = models.IntegerField(default=100) - ar_out_target = models.IntegerField(default=75) + ar_out_target = models.IntegerField() def save(self, *args, **kwargs): if not self.ar_out_target: