bcf-api-xml 0.4.17__tar.gz → 0.4.18__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {bcf_api_xml-0.4.17 → bcf_api_xml-0.4.18}/PKG-INFO +1 -1
- {bcf_api_xml-0.4.17 → bcf_api_xml-0.4.18}/bcf_api_xml/__init__.py +1 -1
- {bcf_api_xml-0.4.17 → bcf_api_xml-0.4.18}/bcf_api_xml/export/excel.py +20 -20
- {bcf_api_xml-0.4.17 → bcf_api_xml-0.4.18}/pyproject.toml +1 -1
- {bcf_api_xml-0.4.17 → bcf_api_xml-0.4.18}/README.md +0 -0
- {bcf_api_xml-0.4.17 → bcf_api_xml-0.4.18}/bcf_api_xml/Schemas/bcf.version +0 -0
- {bcf_api_xml-0.4.17 → bcf_api_xml-0.4.18}/bcf_api_xml/Schemas/markup.xsd +0 -0
- {bcf_api_xml-0.4.17 → bcf_api_xml-0.4.18}/bcf_api_xml/Schemas/project.xsd +0 -0
- {bcf_api_xml-0.4.17 → bcf_api_xml-0.4.18}/bcf_api_xml/Schemas/version.xsd +0 -0
- {bcf_api_xml-0.4.17 → bcf_api_xml-0.4.18}/bcf_api_xml/Schemas/visinfo.xsd +0 -0
- {bcf_api_xml-0.4.17 → bcf_api_xml-0.4.18}/bcf_api_xml/errors.py +0 -0
- {bcf_api_xml-0.4.17 → bcf_api_xml-0.4.18}/bcf_api_xml/export/__init__.py +0 -0
- {bcf_api_xml-0.4.17 → bcf_api_xml-0.4.18}/bcf_api_xml/export/zip.py +0 -0
- {bcf_api_xml-0.4.17 → bcf_api_xml-0.4.18}/bcf_api_xml/import_zip.py +0 -0
- {bcf_api_xml-0.4.17 → bcf_api_xml-0.4.18}/bcf_api_xml/models/ClippingPlane.py +0 -0
- {bcf_api_xml-0.4.17 → bcf_api_xml-0.4.18}/bcf_api_xml/models/Color.py +0 -0
- {bcf_api_xml-0.4.17 → bcf_api_xml-0.4.18}/bcf_api_xml/models/Comment.py +0 -0
- {bcf_api_xml-0.4.17 → bcf_api_xml-0.4.18}/bcf_api_xml/models/Component.py +0 -0
- {bcf_api_xml-0.4.17 → bcf_api_xml-0.4.18}/bcf_api_xml/models/Line.py +0 -0
- {bcf_api_xml-0.4.17 → bcf_api_xml-0.4.18}/bcf_api_xml/models/OrthogonalCamera.py +0 -0
- {bcf_api_xml-0.4.17 → bcf_api_xml-0.4.18}/bcf_api_xml/models/PerspectiveCamera.py +0 -0
- {bcf_api_xml-0.4.17 → bcf_api_xml-0.4.18}/bcf_api_xml/models/Topic.py +0 -0
- {bcf_api_xml-0.4.17 → bcf_api_xml-0.4.18}/bcf_api_xml/models/ViewSetupHints.py +0 -0
- {bcf_api_xml-0.4.17 → bcf_api_xml-0.4.18}/bcf_api_xml/models/Viewpoint.py +0 -0
- {bcf_api_xml-0.4.17 → bcf_api_xml-0.4.18}/bcf_api_xml/models/Visibility.py +0 -0
- {bcf_api_xml-0.4.17 → bcf_api_xml-0.4.18}/bcf_api_xml/models/VisualizationInfo.py +0 -0
- {bcf_api_xml-0.4.17 → bcf_api_xml-0.4.18}/bcf_api_xml/models/XYZ.py +0 -0
- {bcf_api_xml-0.4.17 → bcf_api_xml-0.4.18}/bcf_api_xml/models/__init__.py +0 -0
@@ -13,7 +13,7 @@ def col_to_letter(index):
|
|
13
13
|
return string.ascii_uppercase[index]
|
14
14
|
|
15
15
|
|
16
|
-
|
16
|
+
I18N_TRANSLATIONS = {
|
17
17
|
"en": {
|
18
18
|
"index": "Index",
|
19
19
|
"creation_date": "Date",
|
@@ -49,7 +49,7 @@ HEADER_TRANSLATIONS = {
|
|
49
49
|
"viewpoint": "Image",
|
50
50
|
"models": "Maquettes",
|
51
51
|
"space": "Organisation",
|
52
|
-
"project": "
|
52
|
+
"project": "Projet",
|
53
53
|
"sheetname": "Liste des BCF",
|
54
54
|
},
|
55
55
|
}
|
@@ -89,14 +89,14 @@ def to_xlsx(
|
|
89
89
|
comments: dict(topics_guid=[comment])
|
90
90
|
viewpoints: dict(topics_guid=[viewpoint])
|
91
91
|
"""
|
92
|
-
|
92
|
+
i18n = I18N_TRANSLATIONS[lang]
|
93
93
|
|
94
94
|
xls_file = io.BytesIO()
|
95
95
|
with xlsxwriter.Workbook(xls_file, options={"remove_timezone": True}) as workbook:
|
96
96
|
if sheetname:
|
97
97
|
worksheet = workbook.add_worksheet(sheetname)
|
98
98
|
else:
|
99
|
-
worksheet = workbook.add_worksheet(
|
99
|
+
worksheet = workbook.add_worksheet(i18n["sheetname"])
|
100
100
|
|
101
101
|
# Set default height for tables
|
102
102
|
DEFAULT_CELL_HEIGHT = 220
|
@@ -192,14 +192,14 @@ def to_xlsx(
|
|
192
192
|
row += 1
|
193
193
|
worksheet.set_row_pixels(row, ROW_HEIGHT)
|
194
194
|
worksheet.merge_range("A3:B3", "", merge_format_default)
|
195
|
-
worksheet.write(row, 0,
|
195
|
+
worksheet.write(row, 0, i18n["project"], header_fmt)
|
196
196
|
worksheet.merge_range(f"C3:{LAST_USED_COL_LETTER}3", "", merge_format_default)
|
197
197
|
worksheet.write(row, 2, project["name"], header_fmt2)
|
198
198
|
|
199
199
|
row += 1
|
200
200
|
worksheet.set_row_pixels(row, ROW_HEIGHT)
|
201
201
|
worksheet.merge_range("A4:B4", "", merge_format_default)
|
202
|
-
worksheet.write(row, 0,
|
202
|
+
worksheet.write(row, 0, i18n["space"], header_fmt)
|
203
203
|
worksheet.merge_range(f"C4:{LAST_USED_COL_LETTER}4", "", merge_format_default)
|
204
204
|
worksheet.write(row, 2, space["name"], header_fmt2)
|
205
205
|
|
@@ -223,23 +223,23 @@ def to_xlsx(
|
|
223
223
|
worksheet.set_row(row, TABLE_HEADER_HEIGHT)
|
224
224
|
|
225
225
|
# Create table header
|
226
|
-
worksheet.write(row, INDEX_COL_INDEX,
|
227
|
-
worksheet.write(row, CREATION_DATE_COL_INDEX,
|
226
|
+
worksheet.write(row, INDEX_COL_INDEX, i18n["index"], header_fmt)
|
227
|
+
worksheet.write(row, CREATION_DATE_COL_INDEX, i18n["creation_date"], header_fmt)
|
228
228
|
worksheet.set_column_pixels(CREATION_DATE_COL_INDEX, CREATION_DATE_COL_INDEX, 100)
|
229
|
-
worksheet.write(row, AUTHOR_COL_INDEX,
|
230
|
-
worksheet.write(row, ASSIGNED_TO_COL_INDEX,
|
231
|
-
worksheet.write(row, TITLE_COL_INDEX,
|
232
|
-
worksheet.write(row, VIEWPOINT_COL_INDEX,
|
233
|
-
worksheet.write(row, DESCRIPTION_COL_INDEX,
|
234
|
-
worksheet.write(row, DUE_DATE_COL_INDEX,
|
235
|
-
worksheet.write(row, STAGE_COL_INDEX,
|
236
|
-
worksheet.write(row, STATUS_COL_INDEX,
|
237
|
-
worksheet.write(row, PRIORITY_COL_INDEX,
|
238
|
-
worksheet.write(row, LABELS_COL_INDEX,
|
239
|
-
worksheet.write(row, COMMENTS_COL_INDEX,
|
229
|
+
worksheet.write(row, AUTHOR_COL_INDEX, i18n["author"], header_fmt)
|
230
|
+
worksheet.write(row, ASSIGNED_TO_COL_INDEX, i18n["assigned_to"], header_fmt)
|
231
|
+
worksheet.write(row, TITLE_COL_INDEX, i18n["title"], header_fmt)
|
232
|
+
worksheet.write(row, VIEWPOINT_COL_INDEX, i18n["viewpoint"], header_fmt)
|
233
|
+
worksheet.write(row, DESCRIPTION_COL_INDEX, i18n["description"], header_fmt)
|
234
|
+
worksheet.write(row, DUE_DATE_COL_INDEX, i18n["due_date"], header_fmt)
|
235
|
+
worksheet.write(row, STAGE_COL_INDEX, i18n["stage"], header_fmt)
|
236
|
+
worksheet.write(row, STATUS_COL_INDEX, i18n["status"], header_fmt)
|
237
|
+
worksheet.write(row, PRIORITY_COL_INDEX, i18n["priority"], header_fmt)
|
238
|
+
worksheet.write(row, LABELS_COL_INDEX, i18n["tags"], header_fmt)
|
239
|
+
worksheet.write(row, COMMENTS_COL_INDEX, i18n["comments"], header_fmt)
|
240
240
|
worksheet.set_column_pixels(LABELS_COL_INDEX, LABELS_COL_INDEX, 100)
|
241
241
|
worksheet.set_column_pixels(COMMENTS_COL_INDEX, COMMENTS_COL_INDEX, 200)
|
242
|
-
worksheet.write(row, MODELS_COL_INDEX,
|
242
|
+
worksheet.write(row, MODELS_COL_INDEX, i18n["models"], header_fmt)
|
243
243
|
row += 1
|
244
244
|
|
245
245
|
# Sort topic by index
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|