Merge "color differently finished/unfinished reports (yellow - unfinished, green - finished) PRODX-35956"
diff --git a/testrail_bot/control/migrations/0021_remove_testrailreport_test_run.py b/testrail_bot/control/migrations/0021_remove_testrailreport_test_run.py
new file mode 100644
index 0000000..5dd1b5f
--- /dev/null
+++ b/testrail_bot/control/migrations/0021_remove_testrailreport_test_run.py
@@ -0,0 +1,17 @@
+# Generated by Django 4.2.6 on 2023-10-09 20:20
+
+from django.db import migrations
+
+
+class Migration(migrations.Migration):
+
+ dependencies = [
+ ('control', '0020_auto_20231009_1423'),
+ ]
+
+ operations = [
+ migrations.RemoveField(
+ model_name='testrailreport',
+ name='test_run',
+ ),
+ ]
diff --git a/testrail_bot/control/models.py b/testrail_bot/control/models.py
index f4c846f..e7bea45 100644
--- a/testrail_bot/control/models.py
+++ b/testrail_bot/control/models.py
@@ -24,7 +24,6 @@
class TestRailReport(models.Model):
path = models.FileField(storage=fs, null=True, blank=True, max_length=500)
- test_run = models.ForeignKey(TestRailTestRun, on_delete=models.CASCADE)
report_name = models.CharField(max_length=300)
finished = models.BooleanField(default=False)
created_at = models.DateTimeField(auto_now_add=True)
diff --git a/testrail_bot/control/views.py b/testrail_bot/control/views.py
index db624a6..b12457b 100644
--- a/testrail_bot/control/views.py
+++ b/testrail_bot/control/views.py
@@ -83,7 +83,6 @@
datetime.datetime.min.time()).timestamp()
report = models.TestRailReport(
- test_run=run,
report_name=report_name,
path=path)
report.save()