Skip to content

Commit

Permalink
ITS-403788 | added new status
Browse files Browse the repository at this point in the history
  • Loading branch information
lukaszkarykowski committed Nov 8, 2022
1 parent 7e4843f commit 6516f06
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 1 deletion.
20 changes: 20 additions & 0 deletions src/ralph/back_office/migrations/0014_auto_20221108_1007.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# -*- coding: utf-8 -*-
from __future__ import unicode_literals

from django.db import migrations, models
import ralph.lib.transitions.fields


class Migration(migrations.Migration):

dependencies = [
('back_office', '0013_auto_20220421_1202'),
]

operations = [
migrations.AlterField(
model_name='backofficeasset',
name='status',
field=ralph.lib.transitions.fields.TransitionField(default=1, choices=[(1, 'new'), (2, 'in progress'), (3, 'waiting for release'), (4, 'in use'), (5, 'loan'), (6, 'damaged'), (7, 'liquidated'), (8, 'in service'), (9, 'installed'), (10, 'free'), (11, 'reserved'), (12, 'sale'), (13, 'loan in progress'), (14, 'return in progress'), (15, 'to find'), (16, 'sent'), (17, 'buyout')]),
),
]
1 change: 1 addition & 0 deletions src/ralph/back_office/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,7 @@ class BackOfficeAssetStatus(Choices):
return_in_progress = _("return in progress")
to_find = _("to find")
sent = _("sent")
buyout = _("buyout")


class OfficeInfrastructure(
Expand Down
2 changes: 1 addition & 1 deletion src/ralph/data_importer/tests/test_demo_data.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,5 +11,5 @@ class DemoDataTestCase(TestCase):
def test_demo_data_command(self):
management.call_command('demodata')
self.assertEqual(DataCenterAsset.objects.count(), 422)
self.assertEqual(BackOfficeAsset.objects.count(), 244)
self.assertEqual(BackOfficeAsset.objects.count(), 248)
self.assertEqual(get_user_model().objects.count(), 33)

0 comments on commit 6516f06

Please sign in to comment.