feat: pm 添加工时字段

This commit is contained in:
caoqianming 2024-06-21 15:48:14 +08:00
parent 2bb860f8dd
commit ac7e0a84ea
2 changed files with 23 additions and 0 deletions

View File

@ -0,0 +1,18 @@
# Generated by Django 3.2.12 on 2024-06-21 07:10
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('pm', '0017_auto_20231205_1724'),
]
operations = [
migrations.AddField(
model_name='mtask',
name='hour_work',
field=models.FloatField(blank=True, null=True, verbose_name='工时'),
),
]

View File

@ -8,6 +8,10 @@ TASK_TYPE = (
('mass', '量产'),
('pilot', '中试')
)
SCHEDULE_TYPE = (
('to_day', '排产到天'),
('to_mgroup', '排产到工段')
)
class Utask(CommonBDModel):
@ -82,6 +86,7 @@ class Mtask(CommonADModel):
end_date = models.DateField('计划完工日期')
utask = models.ForeignKey(
Utask, verbose_name='关联大任务', on_delete=models.CASCADE, related_name='mtask_utask', null=True, blank=True)
hour_work = models.FloatField('工时', null=True, blank=True)
peifen_kg = models.FloatField('配粉料数', default=0)
submit_time = models.DateTimeField('提交时间', null=True, blank=True)