Code:
Code: Select all
$issue = array (
'summary' => $summary,
'reporter'=>array('id'=>$uid),
'description' => $descr,
'project'=>array('id'=>$pid),
'category'=>'General',
'version'=>$pversion,
'custom_fields'=>array(
array('field' => array('id'=>1,'name'=>'Reporter Name'),'value'=>$urealname),
array('field' => array('id'=>3,'name'=>'Page Filename'),'value'=>$pg)
)
);
$bid = $mantisClient->mc_issue_add($username, $password, $issue);
Code: Select all
<br />
<b>Fatal error</b>: Uncaught SoapFault exception: [SOAP-ENV:Server] Error Type: APPLICATION ERROR #401,
Error Description: Database query failed. Error received from database was #0: [Microsoft][ODBC SQL Server Driver]Invalid parameter number for the query:
SELECT f.name, f.type, f.access_level_r, f.default_value, f.type, s.value
FROM mantis_custom_field_project_table p
INNER JOIN mantis_custom_field_table f ON f.id = p.field_id
LEFT JOIN mantis_custom_field_string_table s
ON s.field_id = p.field_id AND s.bug_id = ?
WHERE p.project_id = ?
ORDER BY p.sequence ASC, f.name ASC. in C:\~HIDDEN~\includes\savecomment.php:147
Stack trace:
#0 C:\~HIDDEN~\includes\savecomment.php(147): SoapClient->__call('mc_issue_add', Array)
#1 C:\~HIDDEN~\includes\savecomment.php(147): SoapClient->mc_issue_add('aviewer', 'W76d!ffr+5#i4J...', Array)
#2 {main}
thrown in <b>C:\~HIDDEN~\includes\savecomment.php</b> on line <b>147</b><br />
One thing is that even with the above error, the data/information is submitted to mantis correctly and the issue is created. It is just that the call does not return the bug/issue ID.