fix: core_active_backup.py fix docstrings for docs_parser.py

This commit is contained in:
Luboš Zíma
2025-07-13 20:09:26 +07:00
parent 28b7044487
commit eb199c95ca

View File

@ -874,6 +874,8 @@ class ActiveBackupBusiness(base_api.BaseApi):
""" """
Get logs from the package, tasks and devices. Get logs from the package, tasks and devices.
Notes
-----
From `[Activities -> Log]` screen in ABB. From `[Activities -> Log]` screen in ABB.
For specific task logs `[Task List -> Details -> Log]`, specify `task_id` parameter. For specific task logs `[Task List -> Details -> Log]`, specify `task_id` parameter.
@ -1144,75 +1146,77 @@ class ActiveBackupBusiness(base_api.BaseApi):
""" """
Get details of a task result log. Get details of a task result log.
Parameters
----------
result_id : int
ID of the result to get details from.
limit : int, optional
Amount of results to be returned. Defaults to `500`.
order_by : str, optional
What to order the results by. Defaults to `"log_level"`.
Possible values:
- `"log_level"`
- `"log_time"`
direction : str, optional
Direction of the order. Defaults to `"ASC"`.
Possible values:
- `"ASC"`
- `"DESC"`
Returns
-------
dict[str, object]
Dictionary containing a list of result details.
Notes
-----
`result_id` can be retrieved from `list_logs()` function. `result_id` can be retrieved from `list_logs()` function.
Parameters Examples
---------- --------
result_id : int ```json
ID of the result to get details from. {
"data": {
limit : int, optional "count": 2,
Amount of results to be returned. Defaults to `500`. "result_detail_list": [
{
order_by : str, optional "error_code": 0,
What to order the results by. Defaults to `"log_level"`. "log_level": 0,
"log_time": 1741897456,
Possible values: "log_type": 6002,
- `"log_level"` "other_params": {
- `"log_time"` "fs_error": -65,
"os_name": "smb",
direction : str, optional "path": "abc",
Direction of the order. Defaults to `"ASC"`. "task_id": 8
Possible values:
- `"ASC"`
- `"DESC"`
Returns
-------
dict[str, object]
Dictionary containing a list of result details.
Examples
--------
```json
{
"data": {
"count": 2,
"result_detail_list": [
{
"error_code": 0,
"log_level": 0,
"log_time": 1741897456,
"log_type": 6002,
"other_params": {
"fs_error": -65,
"os_name": "smb",
"path": "/D",
"task_id": 8
},
"result_detail_id": 9526,
"result_id": 592
}, },
{ "result_detail_id": 9526,
"error_code": 0, "result_id": 592
"log_level": 0, },
"log_time": 1741897498, {
"log_type": 1104, "error_code": 0,
"other_params": { "log_level": 0,
"os_name": "smb", "log_time": 1741897498,
"path": "", "log_type": 1104,
"task_id": 8, "other_params": {
"task_name": "SMB LAPTOP" "os_name": "smb",
}, "path": "",
"result_detail_id": 9527, "task_id": 8,
"result_id": 592 "task_name": "SMB LAPTOP"
} },
] "result_detail_id": 9527,
}, "result_id": 592
"success": true }
} ]
``` },
"success": true
}
```
""" """
api_name = 'SYNO.ActiveBackup.Log' api_name = 'SYNO.ActiveBackup.Log'
info = self.gen_list[api_name] info = self.gen_list[api_name]