rename: 负责人 -> 运维人员

This commit is contained in:
2026-05-19 15:39:55 +08:00
parent 3a356d5886
commit cabfc54618
4 changed files with 5 additions and 5 deletions

View File

@@ -42,7 +42,7 @@ class Device(models.Model):
default=DeviceStatus.NORMAL,
verbose_name='状态'
)
responsible_person = models.CharField(max_length=50, blank=True, null=True, verbose_name='负责人')
responsible_person = models.CharField(max_length=50, blank=True, null=True, verbose_name='运维人员')
warranty_expire = models.DateField(blank=True, null=True, verbose_name='保修到期日期')
created_at = models.DateTimeField(auto_now_add=True, verbose_name='创建时间')
updated_at = models.DateTimeField(auto_now=True, verbose_name='更新时间')

View File

@@ -94,7 +94,7 @@
<th class="px-4 py-3 text-left font-medium">主IP</th>
<th class="px-4 py-3 text-left font-medium">主序列号</th>
<th class="px-4 py-3 text-left font-medium">状态</th>
<th class="px-4 py-3 text-left font-medium">负责人</th>
<th class="px-4 py-3 text-left font-medium">运维人员</th>
<th class="px-4 py-3 text-left font-medium">服役天数</th>
<th class="px-4 py-3 text-right font-medium">操作</th>
</tr>

View File

@@ -127,7 +127,7 @@ class DeviceViewSet(viewsets.ModelViewSet):
ws.title = '设备列表'
headers = ['ID', '地点', '楼栋', '设备名称', '型号', '品牌', '状态',
'负责人', '启用日期', '主序列号', '主IP', '最近维修简述', '服役天数']
'运维人员', '启用日期', '主序列号', '主IP', '最近维修简述', '服役天数']
for col, header in enumerate(headers, 1):
cell = ws.cell(row=1, column=col, value=header)
cell.font = Font(bold=True)
@@ -176,7 +176,7 @@ class DeviceViewSet(viewsets.ModelViewSet):
'model': str(row.get('型号', '')) if pd.notna(row.get('型号')) else None,
'brand': str(row.get('品牌', '')) if pd.notna(row.get('品牌')) else None,
'status': str(row.get('状态', 'normal')) if pd.notna(row.get('状态')) else 'normal',
'responsible_person': str(row.get('负责人', '')) if pd.notna(row.get('负责人')) else None,
'responsible_person': str(row.get('运维人员', '')) if pd.notna(row.get('运维人员')) else None,
}
device = Device.objects.create(**device_data)