add height to all excel

This commit is contained in:
7nimor
2025-08-02 08:21:04 +03:30
parent ae7bdd76ef
commit f59542252b
3 changed files with 22 additions and 31 deletions

View File

@@ -51,9 +51,9 @@ class WareHouseExcelViewSet(viewsets.ModelViewSet):
]
create_header(worksheet, header_list, 5, 2, height=20, border_style='thin')
create_header(worksheet, header_list, 5, 2, height=25, border_style='thin')
excel_description(worksheet, 'B1', f'ورودی به انبار', row2='C3')
create_header_freez(worksheet, excel_options, 1, 6, 7, height=22, width=20)
create_header_freez(worksheet, excel_options, 1, 6, 7, height=25, width=20)
l = 6
m = 1
@@ -74,14 +74,14 @@ class WareHouseExcelViewSet(viewsets.ModelViewSet):
str(shamsi_date(convert_str_to_date(data['create_date']), in_value=True)) if data.get(
'create_date') else '',
str(data[
'distribution'].get('distribution')) or '-',
'distribution'].get('distribution')) or '-',
data.get('weight') or 0,
data.get('lading_number') or '-',
data.get('delivery_address') or '-',
document_value,
data.get('notes') or '',
]
create_value(worksheet, list1, l + 1, 1, m=m)
create_value(worksheet, list1, l + 1, 1, height=23, m=m)
if document:
worksheet.cell(row=l + 1, column=7).font = Font(color="0563C1", underline='single', bold=True)
m += 1
@@ -105,7 +105,7 @@ class WareHouseExcelViewSet(viewsets.ModelViewSet):
'',
''
]
create_value(worksheet, list2, l + 3, 1, color='gray')
create_value(worksheet, list2, l + 3, 1, color='gray', height=23)
workbook.save(output)
output.seek(0)