mirror of
https://github.com/inventree/InvenTree.git
synced 2025-06-17 20:45:44 +00:00
Added help text for model fields
This commit is contained in:
30
InvenTree/build/migrations/0012_auto_20190508_2332.py
Normal file
30
InvenTree/build/migrations/0012_auto_20190508_2332.py
Normal file
@ -0,0 +1,30 @@
|
||||
# Generated by Django 2.2 on 2019-05-08 13:32
|
||||
|
||||
import django.core.validators
|
||||
from django.db import migrations, models
|
||||
import django.db.models.deletion
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
dependencies = [
|
||||
('build', '0011_auto_20190508_0748'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.AlterField(
|
||||
model_name='build',
|
||||
name='notes',
|
||||
field=models.TextField(blank=True, help_text='Extra build notes'),
|
||||
),
|
||||
migrations.AlterField(
|
||||
model_name='build',
|
||||
name='part',
|
||||
field=models.ForeignKey(help_text='Select part to build', limit_choices_to={'active': True, 'buildable': True}, on_delete=django.db.models.deletion.CASCADE, related_name='builds', to='part.Part'),
|
||||
),
|
||||
migrations.AlterField(
|
||||
model_name='build',
|
||||
name='status',
|
||||
field=models.PositiveIntegerField(choices=[(10, 'Pending'), (20, 'Allocated'), (30, 'Cancelled'), (40, 'Complete')], default=10, help_text='Build status', validators=[django.core.validators.MinValueValidator(0)]),
|
||||
),
|
||||
]
|
@ -47,6 +47,7 @@ class Build(models.Model):
|
||||
'buildable': True,
|
||||
'active': True
|
||||
},
|
||||
help_text='Select part to build',
|
||||
)
|
||||
|
||||
title = models.CharField(
|
||||
@ -75,7 +76,8 @@ class Build(models.Model):
|
||||
|
||||
status = models.PositiveIntegerField(default=PENDING,
|
||||
choices=BUILD_STATUS_CODES.items(),
|
||||
validators=[MinValueValidator(0)])
|
||||
validators=[MinValueValidator(0)],
|
||||
help_text='Build status')
|
||||
|
||||
batch = models.CharField(max_length=100, blank=True, null=True,
|
||||
help_text='Batch code for this build output')
|
||||
@ -92,7 +94,7 @@ class Build(models.Model):
|
||||
|
||||
URL = models.URLField(blank=True, help_text='Link to external URL')
|
||||
|
||||
notes = models.TextField(blank=True)
|
||||
notes = models.TextField(blank=True, help_text='Extra build notes')
|
||||
""" Notes attached to each build output """
|
||||
|
||||
@transaction.atomic
|
||||
|
Reference in New Issue
Block a user