From 6638d376b85c44879154d1f95f70c8098149d1cd Mon Sep 17 00:00:00 2001 From: PCoder Date: Sat, 26 Oct 2019 10:32:49 +0530 Subject: [PATCH] Make HostingBillLineAmount accept negative values --- hosting/migrations/0056_auto_20191026_0454.py | 20 +++++++++++++++++++ hosting/models.py | 2 +- 2 files changed, 21 insertions(+), 1 deletion(-) create mode 100644 hosting/migrations/0056_auto_20191026_0454.py diff --git a/hosting/migrations/0056_auto_20191026_0454.py b/hosting/migrations/0056_auto_20191026_0454.py new file mode 100644 index 00000000..490964bc --- /dev/null +++ b/hosting/migrations/0056_auto_20191026_0454.py @@ -0,0 +1,20 @@ +# -*- coding: utf-8 -*- +# Generated by Django 1.9.4 on 2019-10-26 04:54 +from __future__ import unicode_literals + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('hosting', '0055_auto_20190701_1614'), + ] + + operations = [ + migrations.AlterField( + model_name='hostingbilllineitem', + name='amount', + field=models.IntegerField(), + ), + ] diff --git a/hosting/models.py b/hosting/models.py index 7b08948e..c9ca5efe 100644 --- a/hosting/models.py +++ b/hosting/models.py @@ -466,7 +466,7 @@ class HostingBillLineItem(AssignPermissionsMixin, models.Model): on_delete=models.CASCADE) stripe_plan = models.ForeignKey(StripePlan, null=True, on_delete=models.CASCADE) - amount = models.PositiveSmallIntegerField() + amount = models.IntegerField() description = models.CharField(max_length=255) discountable = models.BooleanField() metadata = models.CharField(max_length=128)