Skip to content

Commit 261a2e6

Browse files
committed
PATCH: add history_count to document serialization and prefetch stuff
1 parent d5f75be commit 261a2e6

File tree

4 files changed

+9
-3
lines changed

4 files changed

+9
-3
lines changed

bimdata_api_client/api/collaboration_api.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8298,7 +8298,7 @@ def create_document(
82988298
):
82998299
"""Create a document # noqa: E501
83008300

8301-
Create a document. If the document is one of {'OBJ', 'DWG', 'IFC', 'GLTF', 'DXF', 'POINT_CLOUD'}, a model will be created and attached to this document Required scopes: document:write # noqa: E501
8301+
Create a document. If the document is one of {'POINT_CLOUD', 'GLTF', 'DXF', 'IFC', 'OBJ', 'DWG'}, a model will be created and attached to this document Required scopes: document:write # noqa: E501
83028302
This method makes a synchronous HTTP request by default. To make an
83038303
asynchronous HTTP request, please pass async_req=True
83048304

bimdata_api_client/model/document.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -131,6 +131,7 @@ def openapi_types():
131131
'ifc_id': (int, none_type,), # noqa: E501
132132
'head_id': (int, none_type,), # noqa: E501
133133
'is_head_version': (bool,), # noqa: E501
134+
'history_count': (int, none_type,), # noqa: E501
134135
'user_permission': (int,), # noqa: E501
135136
'office_preview': (str, none_type,), # noqa: E501
136137
'parent_id': (int, none_type,), # noqa: E501
@@ -159,6 +160,7 @@ def discriminator():
159160
'ifc_id': 'ifc_id', # noqa: E501
160161
'head_id': 'head_id', # noqa: E501
161162
'is_head_version': 'is_head_version', # noqa: E501
163+
'history_count': 'history_count', # noqa: E501
162164
'user_permission': 'user_permission', # noqa: E501
163165
'office_preview': 'office_preview', # noqa: E501
164166
'parent_id': 'parent_id', # noqa: E501
@@ -180,6 +182,7 @@ def discriminator():
180182
'ifc_id', # noqa: E501
181183
'head_id', # noqa: E501
182184
'is_head_version', # noqa: E501
185+
'history_count', # noqa: E501
183186
'user_permission', # noqa: E501
184187
'office_preview', # noqa: E501
185188
}
@@ -188,7 +191,7 @@ def discriminator():
188191

189192
@classmethod
190193
@convert_js_args_to_python_args
191-
def _from_openapi_data(cls, id, created_by, project, name, file, size, tags, visas, created_at, updated_at, model_id, model_type, ifc_id, head_id, is_head_version, user_permission, office_preview, *args, **kwargs): # noqa: E501
194+
def _from_openapi_data(cls, id, created_by, project, name, file, size, tags, visas, created_at, updated_at, model_id, model_type, ifc_id, head_id, is_head_version, history_count, user_permission, office_preview, *args, **kwargs): # noqa: E501
192195
"""Document - a model defined in OpenAPI
193196
194197
Args:
@@ -207,6 +210,7 @@ def _from_openapi_data(cls, id, created_by, project, name, file, size, tags, vis
207210
ifc_id (int, none_type): DEPRECATED: Use 'model_id' instead.
208211
head_id (int, none_type): Document id of head version
209212
is_head_version (bool): Document is a head of version or is owned by another document
213+
history_count (int, none_type): Number of previous versions
210214
user_permission (int): Aggregate of group user permissions and folder default permission
211215
office_preview (str, none_type): Office files will be converted as pdf to provide a web preview. Supported extensions are .ppt, .pptx, .odp, .xls, .xlsx, .ods, .doc, .docx, .odt
212216
@@ -286,6 +290,7 @@ def _from_openapi_data(cls, id, created_by, project, name, file, size, tags, vis
286290
self.ifc_id = ifc_id
287291
self.head_id = head_id
288292
self.is_head_version = is_head_version
293+
self.history_count = history_count
289294
self.user_permission = user_permission
290295
self.office_preview = office_preview
291296
for var_name, var_value in kwargs.items():

docs/CollaborationApi.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1526,7 +1526,7 @@ Name | Type | Description | Notes
15261526
15271527
Create a document
15281528

1529-
Create a document. If the document is one of {'OBJ', 'DWG', 'IFC', 'GLTF', 'DXF', 'POINT_CLOUD'}, a model will be created and attached to this document Required scopes: document:write
1529+
Create a document. If the document is one of {'POINT_CLOUD', 'GLTF', 'DXF', 'IFC', 'OBJ', 'DWG'}, a model will be created and attached to this document Required scopes: document:write
15301530

15311531
### Example
15321532

docs/Document.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ Name | Type | Description | Notes
1919
**ifc_id** | **int, none_type** | DEPRECATED: Use 'model_id' instead. | [readonly]
2020
**head_id** | **int, none_type** | Document id of head version | [readonly]
2121
**is_head_version** | **bool** | Document is a head of version or is owned by another document | [readonly]
22+
**history_count** | **int, none_type** | Number of previous versions | [readonly]
2223
**user_permission** | **int** | Aggregate of group user permissions and folder default permission | [readonly]
2324
**office_preview** | **str, none_type** | Office files will be converted as pdf to provide a web preview. Supported extensions are .ppt, .pptx, .odp, .xls, .xlsx, .ods, .doc, .docx, .odt | [readonly]
2425
**parent_id** | **int, none_type** | | [optional]

0 commit comments

Comments
 (0)