Merge branch 'migration-test'

This commit is contained in:
Oliver Walters 2019-05-02 01:03:08 +10:00
commit 385c13148d
3 changed files with 20 additions and 2 deletions

View File

@ -14,7 +14,6 @@ before_install:
script:
- git ls-files --exclude-standard --others
- test -z "$(git ls-files --exclude-standard --others)"
- make coverage
- make style

View File

@ -0,0 +1,19 @@
# Generated by Django 2.2 on 2019-05-01 14:58
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
dependencies = [
('stock', '0011_auto_20190502_0041'),
]
operations = [
migrations.AlterField(
model_name='stockitem',
name='part',
field=models.ForeignKey(help_text='Base part', on_delete=django.db.models.deletion.CASCADE, related_name='locations', to='part.Part'),
),
]

View File

@ -130,7 +130,7 @@ class StockItem(models.Model):
uuid = models.UUIDField(default=uuid.uuid4, blank=True, editable=False, help_text='Unique ID for the StockItem')
# The 'master' copy of the part of which this stock item is an instance
part = models.ForeignKey('part.Part', on_delete=models.CASCADE, related_name='locations')
part = models.ForeignKey('part.Part', on_delete=models.CASCADE, related_name='locations', help_text='Base part')
# The 'supplier part' used in this instance. May be null if no supplier parts are defined the master part
supplier_part = models.ForeignKey('part.SupplierPart', blank=True, null=True, on_delete=models.SET_NULL)