rename: 负责人 -> 运维人员
This commit is contained in:
@@ -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)
|
||||
|
||||
Reference in New Issue
Block a user