parent
f02faf8772
commit
6a83bf6e14
@ -0,0 +1,67 @@
|
||||
# Generated by Django 3.2.16 on 2023-04-13 21:27
|
||||
|
||||
from django.conf import settings
|
||||
from django.db import migrations, models
|
||||
import django.db.models.deletion
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
initial = True
|
||||
|
||||
dependencies = [
|
||||
('goods_info', '0001_initial'),
|
||||
migrations.swappable_dependency(settings.AUTH_USER_MODEL),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.CreateModel(
|
||||
name='BomProcessModel',
|
||||
fields=[
|
||||
('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
|
||||
('delete_flag', models.CharField(default='0', help_text='是否启用', max_length=1, verbose_name='是否启用')),
|
||||
('create_time', models.DateTimeField(auto_now_add=True, help_text='创建时间', verbose_name='创建时间')),
|
||||
('update_time', models.DateTimeField(auto_now=True, help_text='更新时间', verbose_name='更新时间')),
|
||||
('process_order', models.IntegerField(verbose_name='执行顺序')),
|
||||
('name', models.CharField(max_length=50, verbose_name='工序名称')),
|
||||
('leader_name', models.CharField(max_length=20, verbose_name='负责人的名字')),
|
||||
('money', models.DecimalField(decimal_places=2, default=0, max_digits=10, verbose_name='工价,最多精确到小数点后两位')),
|
||||
('remark', models.CharField(blank=True, max_length=512, null=True, verbose_name='备注')),
|
||||
('leader_user', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='leader1_in_list', to=settings.AUTH_USER_MODEL, verbose_name='负责人员')),
|
||||
('parent_goods', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='process_list', to='goods_info.goodsmodel', verbose_name='当前的生产工序属于哪个货品')),
|
||||
],
|
||||
options={
|
||||
'verbose_name': '生产工序表',
|
||||
'verbose_name_plural': '生产工序表',
|
||||
'db_table': 't_bom_process',
|
||||
'ordering': ['process_order'],
|
||||
},
|
||||
),
|
||||
migrations.CreateModel(
|
||||
name='BomMaterialModel',
|
||||
fields=[
|
||||
('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
|
||||
('delete_flag', models.CharField(default='0', help_text='是否启用', max_length=1, verbose_name='是否启用')),
|
||||
('create_time', models.DateTimeField(auto_now_add=True, help_text='创建时间', verbose_name='创建时间')),
|
||||
('update_time', models.DateTimeField(auto_now=True, help_text='更新时间', verbose_name='更新时间')),
|
||||
('goods_code', models.CharField(max_length=28, verbose_name='货品编号,不让用户填写')),
|
||||
('name', models.CharField(max_length=20, verbose_name='货品名称')),
|
||||
('specification', models.CharField(blank=True, max_length=50, null=True, verbose_name='货品规格')),
|
||||
('model_number', models.CharField(blank=True, max_length=50, null=True, verbose_name='型号')),
|
||||
('units_name', models.CharField(blank=True, max_length=50, null=True, verbose_name='单位名字')),
|
||||
('remark', models.CharField(blank=True, max_length=512, null=True, verbose_name='备注')),
|
||||
('purchase_price', models.DecimalField(blank=True, decimal_places=2, default=0, max_digits=10, verbose_name='采购价')),
|
||||
('count', models.DecimalField(decimal_places=2, default=0, max_digits=10, verbose_name='数量,最多精确到小数点后两位')),
|
||||
('money', models.DecimalField(decimal_places=2, default=0, max_digits=10, verbose_name='费用,最多精确到小数点后两位')),
|
||||
('goods', models.ForeignKey(null=True, on_delete=django.db.models.deletion.SET_NULL, to='goods_info.goodsmodel', verbose_name='货品')),
|
||||
('parent_goods', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='material_list', to='goods_info.goodsmodel', verbose_name='当前的物料清单属于哪个货品')),
|
||||
('units', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, to='goods_info.unitsmodel')),
|
||||
],
|
||||
options={
|
||||
'verbose_name': '生产物料表',
|
||||
'verbose_name_plural': '生产物料表',
|
||||
'db_table': 't_bom_material',
|
||||
'ordering': ['id'],
|
||||
},
|
||||
),
|
||||
]
|
@ -0,0 +1,105 @@
|
||||
# Generated by Django 3.2.16 on 2023-04-22 20:49
|
||||
|
||||
from django.conf import settings
|
||||
from django.db import migrations, models
|
||||
import django.db.models.deletion
|
||||
import django.utils.timezone
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
dependencies = [
|
||||
('goods_info', '0001_initial'),
|
||||
migrations.swappable_dependency(settings.AUTH_USER_MODEL),
|
||||
('sale_info', '0001_initial'),
|
||||
('production_info', '0001_initial'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.CreateModel(
|
||||
name='ProductTaskModel',
|
||||
fields=[
|
||||
('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
|
||||
('delete_flag', models.CharField(default='0', help_text='是否启用', max_length=1, verbose_name='是否启用')),
|
||||
('create_time', models.DateTimeField(auto_now_add=True, help_text='创建时间', verbose_name='创建时间')),
|
||||
('update_time', models.DateTimeField(auto_now=True, help_text='更新时间', verbose_name='更新时间')),
|
||||
('invoices_date', models.DateTimeField(blank=True, default=django.utils.timezone.now, null=True, verbose_name='单据日期')),
|
||||
('number_code', models.CharField(max_length=28, unique=True, verbose_name='编号或者条码')),
|
||||
('name', models.CharField(max_length=20, verbose_name='货品名称')),
|
||||
('specification', models.CharField(blank=True, max_length=50, null=True, verbose_name='货品规格')),
|
||||
('model_number', models.CharField(blank=True, max_length=50, null=True, verbose_name='型号')),
|
||||
('goods_number_code', models.CharField(max_length=28, verbose_name='生产的货品编号或者批号')),
|
||||
('units_name', models.CharField(blank=True, max_length=28, null=True, verbose_name='货品的单位')),
|
||||
('sale_number', models.DecimalField(decimal_places=2, default=1, max_digits=10, verbose_name='订单数量')),
|
||||
('p_number', models.DecimalField(decimal_places=2, default=1, max_digits=10, verbose_name='生产数量')),
|
||||
('finish_date', models.DateField(blank=True, null=True, verbose_name='实际完工日期')),
|
||||
('plan_finish_date', models.DateField(verbose_name='计划完工日期')),
|
||||
('sale_number_code', models.CharField(blank=True, max_length=28, null=True, verbose_name='销售单的编号或者批号')),
|
||||
('status', models.CharField(default='0', max_length=1, verbose_name='状态,0:未审核,1:加工中,2:完工')),
|
||||
('check_number', models.DecimalField(decimal_places=2, default=0, max_digits=10, verbose_name='验收合格数量')),
|
||||
('storage_number', models.DecimalField(decimal_places=2, default=0, max_digits=10, verbose_name='已入库数量')),
|
||||
('cost_money', models.DecimalField(decimal_places=2, default=0, max_digits=10, verbose_name='合计成本')),
|
||||
('remark', models.CharField(blank=True, max_length=512, null=True, verbose_name='备注')),
|
||||
('goods', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, to='goods_info.goodsmodel', verbose_name='货品')),
|
||||
('sale', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, to='sale_info.salemodel', verbose_name='销售单')),
|
||||
],
|
||||
options={
|
||||
'verbose_name': '生产任务表',
|
||||
'verbose_name_plural': '生产任务表',
|
||||
'db_table': 't_product_task',
|
||||
},
|
||||
),
|
||||
migrations.CreateModel(
|
||||
name='ProductProcessModel',
|
||||
fields=[
|
||||
('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
|
||||
('delete_flag', models.CharField(default='0', help_text='是否启用', max_length=1, verbose_name='是否启用')),
|
||||
('create_time', models.DateTimeField(auto_now_add=True, help_text='创建时间', verbose_name='创建时间')),
|
||||
('update_time', models.DateTimeField(auto_now=True, help_text='更新时间', verbose_name='更新时间')),
|
||||
('process_order', models.IntegerField(verbose_name='执行顺序')),
|
||||
('name', models.CharField(max_length=128, verbose_name='工序名称')),
|
||||
('leader_name', models.CharField(max_length=20, verbose_name='负责人的名字')),
|
||||
('price', models.DecimalField(decimal_places=2, default=0, max_digits=10, verbose_name='工价,最多精确到小数点后两位')),
|
||||
('money', models.DecimalField(decimal_places=2, default=0, max_digits=10, verbose_name='费用,最多精确到小数点后两位')),
|
||||
('plan_finish_date', models.DateField(blank=True, null=True, verbose_name='计划完工日期')),
|
||||
('remark', models.CharField(blank=True, max_length=512, null=True, verbose_name='备注')),
|
||||
('leader_user', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='leader2_in_list', to=settings.AUTH_USER_MODEL, verbose_name='负责人员')),
|
||||
('product_task', models.ForeignKey(null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='process_list', to='production_info.producttaskmodel', verbose_name='生产任务')),
|
||||
],
|
||||
options={
|
||||
'verbose_name': '生产工序表',
|
||||
'verbose_name_plural': '生产工序表',
|
||||
'db_table': 't_product_process',
|
||||
},
|
||||
),
|
||||
migrations.CreateModel(
|
||||
name='ProductMaterialModel',
|
||||
fields=[
|
||||
('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
|
||||
('delete_flag', models.CharField(default='0', help_text='是否启用', max_length=1, verbose_name='是否启用')),
|
||||
('create_time', models.DateTimeField(auto_now_add=True, help_text='创建时间', verbose_name='创建时间')),
|
||||
('update_time', models.DateTimeField(auto_now=True, help_text='更新时间', verbose_name='更新时间')),
|
||||
('goods_code', models.CharField(max_length=28, verbose_name='货品编号,不让用户填写')),
|
||||
('name', models.CharField(max_length=20, verbose_name='货品名称')),
|
||||
('specification', models.CharField(blank=True, max_length=50, null=True, verbose_name='货品规格')),
|
||||
('model_number', models.CharField(blank=True, max_length=50, null=True, verbose_name='型号')),
|
||||
('units_name', models.CharField(blank=True, max_length=50, null=True, verbose_name='单位名字')),
|
||||
('remark', models.CharField(blank=True, max_length=512, null=True, verbose_name='备注')),
|
||||
('purchase_price', models.DecimalField(blank=True, decimal_places=2, default=0, max_digits=10, verbose_name='采购价')),
|
||||
('count', models.DecimalField(decimal_places=2, default=0, max_digits=10, verbose_name='总共需要的数量')),
|
||||
('money', models.DecimalField(decimal_places=2, default=0, max_digits=10, verbose_name='费用,最多精确到小数点后两位')),
|
||||
('get_count', models.DecimalField(decimal_places=2, default=0, max_digits=10, verbose_name='已经领取的数量')),
|
||||
('back_count', models.DecimalField(decimal_places=2, default=0, max_digits=10, verbose_name='退回的数量')),
|
||||
('use_count', models.DecimalField(decimal_places=2, default=0, max_digits=10, verbose_name='已使用的数量')),
|
||||
('scrap_count', models.DecimalField(decimal_places=2, default=0, max_digits=10, verbose_name='报废的数量')),
|
||||
('goods', models.ForeignKey(null=True, on_delete=django.db.models.deletion.SET_NULL, to='goods_info.goodsmodel', verbose_name='货品')),
|
||||
('product_task', models.ForeignKey(null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='material_list', to='production_info.producttaskmodel', verbose_name='生产任务')),
|
||||
('units', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, to='goods_info.unitsmodel')),
|
||||
],
|
||||
options={
|
||||
'verbose_name': '生产物料表',
|
||||
'verbose_name_plural': '生产物料表',
|
||||
'db_table': 't_product_material',
|
||||
},
|
||||
),
|
||||
]
|
@ -0,0 +1,26 @@
|
||||
# Generated by Django 3.2.16 on 2023-04-22 21:38
|
||||
|
||||
from django.conf import settings
|
||||
from django.db import migrations, models
|
||||
import django.db.models.deletion
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
dependencies = [
|
||||
migrations.swappable_dependency(settings.AUTH_USER_MODEL),
|
||||
('production_info', '0002_productmaterialmodel_productprocessmodel_producttaskmodel'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.AddField(
|
||||
model_name='producttaskmodel',
|
||||
name='check_user',
|
||||
field=models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='checker6_list', to=settings.AUTH_USER_MODEL, verbose_name='审核人员,不能修改'),
|
||||
),
|
||||
migrations.AddField(
|
||||
model_name='producttaskmodel',
|
||||
name='check_user_name',
|
||||
field=models.CharField(blank=True, max_length=20, null=True, verbose_name='操作人员的真实姓名'),
|
||||
),
|
||||
]
|
@ -0,0 +1,20 @@
|
||||
# Generated by Django 3.2.16 on 2023-04-22 22:11
|
||||
|
||||
from django.db import migrations, models
|
||||
import django.db.models.deletion
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
dependencies = [
|
||||
('production_info', '0003_auto_20230422_2138'),
|
||||
('warehouse_info', '0002_saledeliveritemmodel_saledelivermodel'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.AddField(
|
||||
model_name='saledelivermodel',
|
||||
name='product_task',
|
||||
field=models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, to='production_info.producttaskmodel', verbose_name='所属的生产任务'),
|
||||
),
|
||||
]
|
Loading…
Reference in new issue