Added help text on owner fields

This commit is contained in:
eeintech 2020-12-01 17:46:11 -05:00
parent 8dac6bb982
commit c9b3c16c6f
2 changed files with 4 additions and 2 deletions

View File

@ -17,11 +17,11 @@ class Migration(migrations.Migration):
migrations.AddField( migrations.AddField(
model_name='stockitem', model_name='stockitem',
name='owner', name='owner',
field=models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='owner_stockitems', to=settings.AUTH_USER_MODEL), field=models.ForeignKey(blank=True, help_text='Owner (User)', null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='owner_stockitems', to=settings.AUTH_USER_MODEL),
), ),
migrations.AddField( migrations.AddField(
model_name='stocklocation', model_name='stocklocation',
name='owner', name='owner',
field=models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='owner_stocklocations', to='auth.Group'), field=models.ForeignKey(blank=True, help_text='Owner (Group)', null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='owner_stocklocations', to='auth.Group'),
), ),
] ]

View File

@ -45,6 +45,7 @@ class StockLocation(InvenTreeTree):
""" """
owner = models.ForeignKey(Group, on_delete=models.SET_NULL, blank=True, null=True, owner = models.ForeignKey(Group, on_delete=models.SET_NULL, blank=True, null=True,
help_text='Owner (Group)',
related_name='owner_stocklocations') related_name='owner_stocklocations')
def get_absolute_url(self): def get_absolute_url(self):
@ -463,6 +464,7 @@ class StockItem(MPTTModel):
) )
owner = models.ForeignKey(User, on_delete=models.SET_NULL, blank=True, null=True, owner = models.ForeignKey(User, on_delete=models.SET_NULL, blank=True, null=True,
help_text='Owner (User)',
related_name='owner_stockitems') related_name='owner_stockitems')
def clearAllocations(self): def clearAllocations(self):