Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
bugzilla
Project
Project
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
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
etersoft
bugzilla
Commits
b494561c
Commit
b494561c
authored
Nov 23, 2012
by
Thorsten Schöning
Committed by
Frédéric Buclin
Nov 23, 2012
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Bug 385283: bz_webservice_demo.pl --product-name fails (Product.get_product no longer exists)
Part 2: correctly display components, milestones and versions r/a=LpSolit
parent
0ec77fdc
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
6 deletions
+14
-6
bz_webservice_demo.pl
contrib/bz_webservice_demo.pl
+14
-6
No files found.
contrib/bz_webservice_demo.pl
View file @
b494561c
...
...
@@ -301,16 +301,24 @@ The call will return a C<Bugzilla::Product> object.
if
(
$product_name
)
{
$soapresult
=
$proxy
->
call
(
'Product.get'
,
{
'names'
=>
[
$product_name
]});
_die_on_fault
(
$soapresult
);
$result
=
$soapresult
->
result
;
$result
=
$soapresult
->
result
()
->
{
'products'
}
->
[
0
]
;
if
(
ref
(
$result
)
eq
'HASH'
)
{
$result
=
$result
->
{
'products'
}
->
[
0
];
foreach
(
keys
(
%
$result
))
{
print
"$_: $result->{$_}\n"
;
# Iterate all entries, the values may be scalars or array refs with hash refs.
foreach
my
$key
(
sort
(
keys
%
$result
))
{
my
$value
=
$result
->
{
$key
};
if
(
ref
(
$value
))
{
my
$counter
=
0
;
foreach
my
$hash
(
@$value
)
{
while
(
my
(
$innerKey
,
$innerValue
)
=
each
%
$hash
)
{
print
"$key.$counter.$innerKey: $innerValue\n"
;
}
++
$counter
;
}
}
else
{
print
"$result\n"
;
print
"$key: $value\n"
}
}
}
...
...
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