Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
python-kitgvapi
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
1
Issues
1
List
Boards
Labels
Service Desk
Milestones
Merge Requests
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
jens.kleineheismann
python-kitgvapi
Commits
58fa9205
Commit
58fa9205
authored
Apr 03, 2019
by
Daniel Bacher
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add option ad_details
parent
d866ae7c
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
3 deletions
+5
-3
kitgvapi/clients.py
kitgvapi/clients.py
+3
-1
kitgvapi/models.py
kitgvapi/models.py
+2
-2
No files found.
kitgvapi/clients.py
View file @
58fa9205
...
...
@@ -122,8 +122,10 @@ class RestClient(object):
path
=
'/oe/name/{pk}'
.
format
(
pk
=
pk
)
return
self
.
get
(
path
)
def
get_oe_groups
(
self
,
pk
,
pk_only
=
False
):
def
get_oe_groups
(
self
,
pk
,
pk_only
=
False
,
ad_details
=
False
):
path
=
'/groups/{pk}'
.
format
(
pk
=
pk
)
if
ad_details
:
path
+=
"?addAdDetails=true"
l
=
self
.
get
(
path
)
if
pk_only
:
l
=
[
d
[
SYMBOLS
[
'GROUP_PK_ATTRIB'
]]
for
d
in
l
]
...
...
kitgvapi/models.py
View file @
58fa9205
...
...
@@ -105,9 +105,9 @@ class Oe(Model):
def
_save_data_attribs
(
self
):
raise
NotImplementedError
(
'Not supported'
)
def
get_groups
(
self
):
def
get_groups
(
self
,
ad_details
=
False
):
self
.
load
()
l
=
self
.
client
.
get_oe_groups
(
pk
=
self
.
pk
)
l
=
self
.
client
.
get_oe_groups
(
pk
=
self
.
pk
,
ad_details
=
ad_details
)
for
d
in
l
:
y
=
Group
(
client
=
self
.
client
,
data
=
d
)
yield
y
...
...
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