Part attachment comment field is required

This commit is contained in:
Oliver Walters 2019-05-18 16:20:48 +10:00
parent a2dbdfe794
commit 613c96e093
2 changed files with 19 additions and 1 deletions

View File

@ -0,0 +1,18 @@
# Generated by Django 2.2 on 2019-05-18 06:20
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('part', '0026_remove_supplierpart_single_price'),
]
operations = [
migrations.AlterField(
model_name='partattachment',
name='comment',
field=models.CharField(help_text='File comment', max_length=100),
),
]

View File

@ -644,7 +644,7 @@ class PartAttachment(models.Model):
attachment = models.FileField(upload_to=attach_file, null=True, blank=True, attachment = models.FileField(upload_to=attach_file, null=True, blank=True,
help_text='Select file to attach') help_text='Select file to attach')
comment = models.CharField(max_length=100, blank=True, help_text='File comment') comment = models.CharField(max_length=100, help_text='File comment')
@property @property
def basename(self): def basename(self):