Testopia:Documentation:XMLRPC:Product: Difference between revisions

From MozillaWiki
Jump to navigation Jump to search
No edit summary
No edit summary
Line 2: Line 2:
Back to [[Testopia:Documentation:XMLRPC]]
Back to [[Testopia:Documentation:XMLRPC]]


==Component==
==Product==


===Description===
===Description===
Each test case must be linked to one or more test plans.
An object representing a Testopia product.


===Hiearchy===
===Hiearchy===
Bugzilla::WebService::Component
Bugzilla::WebService::Testopia::Product


===Attributes===
===Attributes===


{| border=1 cellpadding=4
{| border=1 cellpadding=4
| '''Attribute''' || '''Data Type''' || '''Comments''' || '''Create''' || '''Read''' || '''Update'''
| '''Attribute''' || '''Data Type''' || '''Comments'''  
|-
|-
| description || string || || || X ||
| id || integer ||
|-
|-
| id || integer || || || X ||
| name || string ||
|-
|-
| initialowner || integer || || || X ||
| description || string ||
|-
|-
| initialqacontact || integer || || || X ||
| milestone_url || string ||
|-
|-
| name || String || || || X ||
| disallow_new || integer ||
|-
| votes_per_user || integer ||
|-
| max_votes_per_bug || integer ||
|-
| votes_to_confirm || integer ||
|-
| default_milestone || string ||
|-
| classification_id || integer ||
|-
|-
| product_id || integer || || || X ||
|}
|}


Line 32: Line 41:


----
----
====get - Get A Component by ID====
====lookup_id_by_name - Lookup A Product ID By Its Name====
----
 
=====Usage=====
Product.lookup_id_by_name
 
=====Parameters=====
{| border=1 cellpadding=4
| '''Parameter''' || '''Data Type''' || '''Comments'''
|-
| name || string || Cannot be null or empty string
|-
|}
 
 
=====Result=====
The product id for the respective name or 0 if an error occurs.
 
=====Example=====
<b>Perl</b>
my $product_name = 'Product Name';
$proxy->call('Product.lookup_id_by_name', 'Product Name');
 
 
 
----
====lookup_name_by_id - Lookup A Product Name By Its ID====
----
 
=====Usage=====
Product.lookup_name_by_id
 
=====Parameters=====
{| border=1 cellpadding=4
| '''Parameter''' || '''Data Type''' || '''Comments'''
|-
| id || integer || Cannot be 0
|-
|}
 
 
=====Result=====
The product name for the respective id or empty string if an error occurs.
 
=====Example=====
<b>Perl</b>
my $product_id = 1;
$proxy->call('Product.lookup_name_by_id', $product_id);
 
 
 
----
====get_milestones - Get a list of milestones for the given Product====
----
----


=====Usage=====
=====Usage=====
Component.get
Product.get_milestones


=====Parameters=====
=====Parameters=====
Line 42: Line 103:
| '''Parameter''' || '''Data Type''' || '''Comments'''  
| '''Parameter''' || '''Data Type''' || '''Comments'''  
|-
|-
| component_id || integer || Must be greater than 0.
| product_id || integer ||
|-
|-
|}
|}
Line 48: Line 109:


=====Result=====
=====Result=====
A hash map of key/value pairs for the attributes listed above or a hash map containing values for the keys, "faultcode" and "faultstring".
An array of Milestone hash maps or a hash map containing values for the keys, "faultcode" and "faultstring".


=====Example=====
=====Example=====
<b>Perl</b>
<b>Perl</b>
  my $component_id = 1;
  my $product_id = 1;
  my $result = $proxy->call('Component.get', $component_id);
  $proxy->call('Product.lookup_name_by_id', $product_id);


<br>Back to [[Testopia]]
<br>Back to [[Testopia]]

Revision as of 20:49, 25 September 2007

Back to Testopia:Documentation:XMLRPC

Product

Description

An object representing a Testopia product.

Hiearchy

Bugzilla::WebService::Testopia::Product

Attributes

Attribute Data Type Comments
id integer
name string
description string
milestone_url string
disallow_new integer
votes_per_user integer
max_votes_per_bug integer
votes_to_confirm integer
default_milestone string
classification_id integer


Methods


lookup_id_by_name - Lookup A Product ID By Its Name


Usage

Product.lookup_id_by_name

Parameters
Parameter Data Type Comments
name string Cannot be null or empty string


Result

The product id for the respective name or 0 if an error occurs.

Example

Perl

my $product_name = 'Product Name';
$proxy->call('Product.lookup_id_by_name', 'Product Name');



lookup_name_by_id - Lookup A Product Name By Its ID


Usage

Product.lookup_name_by_id

Parameters
Parameter Data Type Comments
id integer Cannot be 0


Result

The product name for the respective id or empty string if an error occurs.

Example

Perl

my $product_id = 1;
$proxy->call('Product.lookup_name_by_id', $product_id);



get_milestones - Get a list of milestones for the given Product


Usage

Product.get_milestones

Parameters
Parameter Data Type Comments
product_id integer


Result

An array of Milestone hash maps or a hash map containing values for the keys, "faultcode" and "faultstring".

Example

Perl

my $product_id = 1;
$proxy->call('Product.lookup_name_by_id', $product_id);


Back to Testopia