mirror of
https://github.com/inventree/InvenTree.git
synced 2025-06-16 03:55:41 +00:00
Add "pack_units" field to the SupplierPart model
This commit is contained in:
18
InvenTree/company/migrations/0059_supplierpart_pack_units.py
Normal file
18
InvenTree/company/migrations/0059_supplierpart_pack_units.py
Normal file
@ -0,0 +1,18 @@
|
|||||||
|
# Generated by Django 3.2.19 on 2023-05-19 03:41
|
||||||
|
|
||||||
|
from django.db import migrations, models
|
||||||
|
|
||||||
|
|
||||||
|
class Migration(migrations.Migration):
|
||||||
|
|
||||||
|
dependencies = [
|
||||||
|
('company', '0058_auto_20230515_0004'),
|
||||||
|
]
|
||||||
|
|
||||||
|
operations = [
|
||||||
|
migrations.AddField(
|
||||||
|
model_name='supplierpart',
|
||||||
|
name='pack_units',
|
||||||
|
field=models.CharField(blank=True, help_text='Units of measure for this supplier part', max_length=25, verbose_name='Packaging Units'),
|
||||||
|
),
|
||||||
|
]
|
@ -561,6 +561,13 @@ class SupplierPart(MetadataMixin, InvenTreeBarcodeMixin, common.models.MetaMixin
|
|||||||
|
|
||||||
packaging = models.CharField(max_length=50, blank=True, null=True, verbose_name=_('Packaging'), help_text=_('Part packaging'))
|
packaging = models.CharField(max_length=50, blank=True, null=True, verbose_name=_('Packaging'), help_text=_('Part packaging'))
|
||||||
|
|
||||||
|
pack_units = models.CharField(
|
||||||
|
max_length=25,
|
||||||
|
verbose_name=_('Packaging Units'),
|
||||||
|
help_text=_('Units of measure for this supplier part'),
|
||||||
|
blank=True,
|
||||||
|
)
|
||||||
|
|
||||||
pack_size = RoundingDecimalField(
|
pack_size = RoundingDecimalField(
|
||||||
verbose_name=_('Pack Quantity'),
|
verbose_name=_('Pack Quantity'),
|
||||||
help_text=_('Unit quantity supplied in a single pack'),
|
help_text=_('Unit quantity supplied in a single pack'),
|
||||||
|
Reference in New Issue
Block a user