feat: 添加工时字段
This commit is contained in:
parent
5efd9888dd
commit
2bb860f8dd
|
@ -0,0 +1,18 @@
|
|||
# Generated by Django 3.2.12 on 2024-06-21 06:31
|
||||
|
||||
from django.db import migrations, models
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
dependencies = [
|
||||
('mtm', '0029_auto_20240528_1428'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.AddField(
|
||||
model_name='route',
|
||||
name='hour_work',
|
||||
field=models.FloatField(blank=True, null=True, verbose_name='工时'),
|
||||
),
|
||||
]
|
|
@ -182,6 +182,7 @@ class Route(CommonADModel):
|
|||
Material, verbose_name='主要输出物料', on_delete=models.CASCADE, related_name='route_material_out', null=True, blank=True)
|
||||
is_count_utask = models.BooleanField('是否主任务统计', default=False)
|
||||
out_rate = models.FloatField('出材率', default=100, blank=True)
|
||||
hour_work = models.FloatField('工时', null=True, blank=True)
|
||||
|
||||
@staticmethod
|
||||
def get_routes(material: Material, autotask: bool = False):
|
||||
|
|
Loading…
Reference in New Issue