Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
C
cake-bot
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Oleksandr Barabash
cake-bot
Commits
f07a07e2
Commit
f07a07e2
authored
Dec 06, 2022
by
Oleksandr Barabash
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
paging object added
parent
b0e0d18f
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
5 deletions
+5
-5
app.py
app.py
+5
-5
No files found.
app.py
View file @
f07a07e2
...
...
@@ -88,16 +88,16 @@ async def v1_get_initiations(request: Request) -> Response:
notification_id
=
request
.
match_info
.
get
(
'notification_id'
)
Log
.
d
(
TAG
,
"v1_get_initiations::notification_id: "
"{}"
.
format
(
notification_id
))
init_items
,
next
_token
=
await
COSMOS_CLIENT
.
get_initiation_items
(
init_items
,
paging
_token
=
await
COSMOS_CLIENT
.
get_initiation_items
(
notification_id
,
token
)
data
=
dict
(
initiators
=
[
dict
(
initiator
=
i
.
initiator
,
timestamp
=
i
.
timestamp
,
id
=
i
.
id
)
for
i
in
init_items
])
Log
.
d
(
TAG
,
"v1_get_initiations::
next_token: {}"
.
format
(
next
_token
))
if
next
_token
is
not
None
:
token_encoded
=
quote_b64encode_str_safe
(
next
_token
)
data
.
update
(
dict
(
token
=
token_encoded
))
Log
.
d
(
TAG
,
"v1_get_initiations::
paging_token: {}"
.
format
(
paging
_token
))
if
paging
_token
is
not
None
:
token_encoded
=
quote_b64encode_str_safe
(
paging
_token
)
data
.
update
(
dict
(
paging
=
dict
(
token
=
token_encoded
)
))
body
=
dict
(
status
=
dict
(
message
=
"OK"
,
code
=
200
),
data
=
data
)
return
Response
(
body
=
json
.
dumps
(
body
),
status
=
HTTPStatus
.
OK
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment