[Fusionforge-commits] r10532 - in trunk/src/plugins/mantisbt: action action/admin controler view view/admin www

Franck VILLAUME nerville at libremir.placard.fr.eu.org
Fri Sep 17 14:57:42 CEST 2010


Author: nerville
Date: 2010-09-17 14:57:42 +0200 (Fri, 17 Sep 2010)
New Revision: 10532

Modified:
   trunk/src/plugins/mantisbt/action/addAttachment.php
   trunk/src/plugins/mantisbt/action/addIssue.php
   trunk/src/plugins/mantisbt/action/addNote.php
   trunk/src/plugins/mantisbt/action/admin/addCategory.php
   trunk/src/plugins/mantisbt/action/admin/addVersion.php
   trunk/src/plugins/mantisbt/action/admin/deleteCategory.php
   trunk/src/plugins/mantisbt/action/admin/deleteVersion.php
   trunk/src/plugins/mantisbt/action/admin/renameCategory.php
   trunk/src/plugins/mantisbt/action/admin/updateVersion.php
   trunk/src/plugins/mantisbt/action/deleteAttachment.php
   trunk/src/plugins/mantisbt/action/deleteNote.php
   trunk/src/plugins/mantisbt/action/updateIssue.php
   trunk/src/plugins/mantisbt/action/updateNote.php
   trunk/src/plugins/mantisbt/controler/filter.php
   trunk/src/plugins/mantisbt/view/addIssue.php
   trunk/src/plugins/mantisbt/view/addOrEditNote.php
   trunk/src/plugins/mantisbt/view/admin/StatPerStatus.php
   trunk/src/plugins/mantisbt/view/admin/viewCategorie.php
   trunk/src/plugins/mantisbt/view/admin/viewVersion.php
   trunk/src/plugins/mantisbt/view/editIssue.php
   trunk/src/plugins/mantisbt/view/roadmap.php
   trunk/src/plugins/mantisbt/view/viewAttachment.php
   trunk/src/plugins/mantisbt/view/viewIssue.php
   trunk/src/plugins/mantisbt/view/viewIssues.php
   trunk/src/plugins/mantisbt/view/viewNote.php
   trunk/src/plugins/mantisbt/www/index.php
Log:
remove sys_mantisbt_host -> forge_get_config & catch all SOAP errors

Modified: trunk/src/plugins/mantisbt/action/addAttachment.php
===================================================================
--- trunk/src/plugins/mantisbt/action/addAttachment.php	2010-09-17 12:42:34 UTC (rev 10531)
+++ trunk/src/plugins/mantisbt/action/addAttachment.php	2010-09-17 12:57:42 UTC (rev 10532)
@@ -24,7 +24,7 @@
 $data = file_get_contents ($_FILES['attachment']['tmp_name'] );
 $content = base64_encode ($data);
 try {
-    $clientSOAP = new SoapClient("http://$sys_mantisbt_host/api/soap/mantisconnect.php?wsdl", array('trace'=>true, 'exceptions'=>true));
+    $clientSOAP = new SoapClient("http://".forge_get_config('server','mantisbt')."/api/soap/mantisconnect.php?wsdl", array('trace'=>true, 'exceptions'=>true));
     $clientSOAP->__soapCall('mc_issue_attachment_add', array("username" => $username, "password" => $password, "issue_id" => $idBug, "name" => $_FILES['attachment']['name'], "file_type" => $_FILES['attachment']['type'], "content" => $content ));
     $feedback = 'Opération réussie';
 } catch (SoapFault $soapFault) {

Modified: trunk/src/plugins/mantisbt/action/addIssue.php
===================================================================
--- trunk/src/plugins/mantisbt/action/addIssue.php	2010-09-17 12:42:34 UTC (rev 10531)
+++ trunk/src/plugins/mantisbt/action/addIssue.php	2010-09-17 12:57:42 UTC (rev 10532)
@@ -26,7 +26,7 @@
 $defect['project']['id'] = $idProjetMantis;
 
 try {
-    $clientSOAP = new SoapClient("http://$sys_mantisbt_host/api/soap/mantisconnect.php?wsdl", array('trace'=>true, 'exceptions'=>true));
+    $clientSOAP = new SoapClient("http://".forge_get_config('server','mantisbt')."/api/soap/mantisconnect.php?wsdl", array('trace'=>true, 'exceptions'=>true));
     $listSeverities = $clientSOAP->__soapCall('mc_enum_severities', array("username" => $username, "password" => $password));
     $listReproducibilities = $clientSOAP->__soapCall('mc_enum_reproducibilities', array("username" => $username, "password" => $password));
     $listUsers = $clientSOAP->__soapCall('mc_project_get_users', array("username" => $username, "password" => $password, "project_id" => $idProjetMantis, "acces" => 10));

Modified: trunk/src/plugins/mantisbt/action/addNote.php
===================================================================
--- trunk/src/plugins/mantisbt/action/addNote.php	2010-09-17 12:42:34 UTC (rev 10531)
+++ trunk/src/plugins/mantisbt/action/addNote.php	2010-09-17 12:57:42 UTC (rev 10532)
@@ -21,7 +21,7 @@
  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
  */
 
-$clientSOAP = new SoapClient("http://$sys_mantisbt_host/api/soap/mantisconnect.php?wsdl", array('trace'=>true, 'exceptions'=>true));
+$clientSOAP = new SoapClient("http://".forge_get_config('server','mantisbt')."/api/soap/mantisconnect.php?wsdl", array('trace'=>true, 'exceptions'=>true));
 $noteEdit;
 
 $note['text'] = $_POST['edit_texte_note'];

Modified: trunk/src/plugins/mantisbt/action/admin/addCategory.php
===================================================================
--- trunk/src/plugins/mantisbt/action/admin/addCategory.php	2010-09-17 12:42:34 UTC (rev 10531)
+++ trunk/src/plugins/mantisbt/action/admin/addCategory.php	2010-09-17 12:57:42 UTC (rev 10532)
@@ -27,7 +27,7 @@
 
 if ($nameCategory != "") {
     try {
-	    $clientSOAP = new SoapClient("http://$sys_mantisbt_host/api/soap/mantisconnect.php?wsdl", array('trace'=>true, 'exceptions'=>true));
+	    $clientSOAP = new SoapClient("http://".forge_get_config('server','mantisbt')."/api/soap/mantisconnect.php?wsdl", array('trace'=>true, 'exceptions'=>true));
 	    $clientSOAP->__soapCall('mc_project_add_category', array("username" => $username, "password" => $password, "p_project_id" => $idProjetMantis, "p_category_name" => $nameCategory));
     } catch (SoapFault $soapFault) {
         $feedback = 'Error : '.$soapFault->faultstring;

Modified: trunk/src/plugins/mantisbt/action/admin/addVersion.php
===================================================================
--- trunk/src/plugins/mantisbt/action/admin/addVersion.php	2010-09-17 12:42:34 UTC (rev 10531)
+++ trunk/src/plugins/mantisbt/action/admin/addVersion.php	2010-09-17 12:57:42 UTC (rev 10532)
@@ -30,7 +30,7 @@
 	$versionStruct['description'] = '';
 	$versionStruct['date_order'] = '';
     try {
-        $clientSOAP = new SoapClient("http://$sys_mantisbt_host/api/soap/mantisconnect.php?wsdl", array('trace'=>true, 'exceptions'=>true));
+        $clientSOAP = new SoapClient("http://".forge_get_config('server','mantisbt')."/api/soap/mantisconnect.php?wsdl", array('trace'=>true, 'exceptions'=>true));
         $clientSOAP->__soapCall('mc_project_version_add', array("username" => $username, "password" => $password, "version" => $versionStruct));
         if (isset($_POST['transverse'])) {
             $listChild = $clientSOAP->__soapCall('mc_project_get_subprojects', array("username" => $username, "password" => $password, "project_id" => $idProjetMantis));

Modified: trunk/src/plugins/mantisbt/action/admin/deleteCategory.php
===================================================================
--- trunk/src/plugins/mantisbt/action/admin/deleteCategory.php	2010-09-17 12:42:34 UTC (rev 10531)
+++ trunk/src/plugins/mantisbt/action/admin/deleteCategory.php	2010-09-17 12:57:42 UTC (rev 10532)
@@ -27,7 +27,7 @@
 
 if ($deleteCategory) {
     try {
-	    $clientSOAP = new SoapClient("http://$sys_mantisbt_host/api/soap/mantisconnect.php?wsdl", array('trace'=>true, 'exceptions'=>true));
+	    $clientSOAP = new SoapClient("http://".forge_get_config('server','mantisbt')."/api/soap/mantisconnect.php?wsdl", array('trace'=>true, 'exceptions'=>true));
 	    $clientSOAP->__soapCall('mc_project_delete_category', array("username" => $username, "password" => $password, "p_project_id" => $idProjetMantis, "p_category_name" => $deleteCategory));
     } catch (SoapFault $soapFault) {
         $msg = 'Error : '.$soapFault->faultstring;

Modified: trunk/src/plugins/mantisbt/action/admin/deleteVersion.php
===================================================================
--- trunk/src/plugins/mantisbt/action/admin/deleteVersion.php	2010-09-17 12:42:34 UTC (rev 10531)
+++ trunk/src/plugins/mantisbt/action/admin/deleteVersion.php	2010-09-17 12:57:42 UTC (rev 10532)
@@ -27,7 +27,7 @@
 
 if ($deleteVersion) {
     try {
-	    $clientSOAP = new SoapClient("http://$sys_mantisbt_host/api/soap/mantisconnect.php?wsdl", array('trace'=>true, 'exceptions'=>true));
+	    $clientSOAP = new SoapClient("http://".forge_get_config('server','mantisbt')."/api/soap/mantisconnect.php?wsdl", array('trace'=>true, 'exceptions'=>true));
 	    $clientSOAP->__soapCall('mc_project_version_delete', array("username" => $username, "password" => $password, "version_id" => $deleteVersion));
     } catch (SoapFault $soapFault) {
         $msg = 'Erreur : '.$soapFault->faultstring;

Modified: trunk/src/plugins/mantisbt/action/admin/renameCategory.php
===================================================================
--- trunk/src/plugins/mantisbt/action/admin/renameCategory.php	2010-09-17 12:42:34 UTC (rev 10531)
+++ trunk/src/plugins/mantisbt/action/admin/renameCategory.php	2010-09-17 12:57:42 UTC (rev 10532)
@@ -28,7 +28,7 @@
 
 if ( $newCategoryName && $renameCategory ) {
     try {
-	    $clientSOAP = new SoapClient("http://$sys_mantisbt_host/api/soap/mantisconnect.php?wsdl", array('trace'=>true, 'exceptions'=>true));
+	    $clientSOAP = new SoapClient("http://".forge_get_config('server','mantisbt')."/api/soap/mantisconnect.php?wsdl", array('trace'=>true, 'exceptions'=>true));
 	    $clientSOAP->__soapCall('mc_project_rename_category_by_name', array("username" => $username, "password" => $password, "p_project_id" => $idProjetMantis, "p_category_name" => $renameCategory, "p_category_name_new" => $newCategoryName, "p_assigned_to" => ''));
     } catch (SoapFault $soapFault) {
         $msg = 'Error : '.$soapFault->faultstring;

Modified: trunk/src/plugins/mantisbt/action/admin/updateVersion.php
===================================================================
--- trunk/src/plugins/mantisbt/action/admin/updateVersion.php	2010-09-17 12:42:34 UTC (rev 10531)
+++ trunk/src/plugins/mantisbt/action/admin/updateVersion.php	2010-09-17 12:57:42 UTC (rev 10532)
@@ -38,7 +38,7 @@
 $version_data['description'] = '';
 
 try {
-    $clientSOAP = new SoapClient("http://$sys_mantisbt_host/api/soap/mantisconnect.php?wsdl", array('trace'=>true, 'exceptions'=>true));
+    $clientSOAP = new SoapClient("http://".forge_get_config('server','mantisbt')."/api/soap/mantisconnect.php?wsdl", array('trace'=>true, 'exceptions'=>true));
     $clientSOAP->__soapCall('mc_project_version_update', array("username" => $username, "password" => $password, "version_id" => $version_id, "version" => $version_data));
     if (isset($_POST['transverse'])) {
         $listChild = $clientSOAP->__soapCall('mc_project_get_subprojects', array("username" => $username, "password" => $password, "project_id" => $idProjetMantis));

Modified: trunk/src/plugins/mantisbt/action/deleteAttachment.php
===================================================================
--- trunk/src/plugins/mantisbt/action/deleteAttachment.php	2010-09-17 12:42:34 UTC (rev 10531)
+++ trunk/src/plugins/mantisbt/action/deleteAttachment.php	2010-09-17 12:57:42 UTC (rev 10532)
@@ -24,7 +24,7 @@
 $idAttachment = getIntFromRequest('idAttachment');
 if ($idAttachment) {
     try {
-        $clientSOAP = new SoapClient("http://$sys_mantisbt_host/api/soap/mantisconnect.php?wsdl", array('trace'=>true, 'exceptions'=>true));
+        $clientSOAP = new SoapClient("http://".forge_get_config('server','mantisbt')."/api/soap/mantisconnect.php?wsdl", array('trace'=>true, 'exceptions'=>true));
 	    $clientSOAP->__soapCall('mc_issue_attachment_delete', array("username" => $username, "password" => $password, "issue_attachment_id" => $idAttachment));
     } catch (SoapFault $soapFault) {
         echo 'Error : '.$soapFault->faultstring;

Modified: trunk/src/plugins/mantisbt/action/deleteNote.php
===================================================================
--- trunk/src/plugins/mantisbt/action/deleteNote.php	2010-09-17 12:42:34 UTC (rev 10531)
+++ trunk/src/plugins/mantisbt/action/deleteNote.php	2010-09-17 12:57:42 UTC (rev 10532)
@@ -22,7 +22,7 @@
  */
 
 try {
-    $clientSOAP = new SoapClient("http://$sys_mantisbt_host/api/soap/mantisconnect.php?wsdl", array('trace'=>true, 'exceptions'=>true));
+    $clientSOAP = new SoapClient("http://".forge_get_config('server','mantisbt')."/api/soap/mantisconnect.php?wsdl", array('trace'=>true, 'exceptions'=>true));
     $clientSOAP->__soapCall('mc_issue_note_delete', array("username" => $username, "password" => $password, "issue_note_id" => $idNote));
 } catch (SoapFault $soapFault) {
     $feedback = 'Error : '.$soapFault->faultstring;

Modified: trunk/src/plugins/mantisbt/action/updateIssue.php
===================================================================
--- trunk/src/plugins/mantisbt/action/updateIssue.php	2010-09-17 12:42:34 UTC (rev 10531)
+++ trunk/src/plugins/mantisbt/action/updateIssue.php	2010-09-17 12:57:42 UTC (rev 10532)
@@ -22,7 +22,7 @@
  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
  */
 
-$clientSOAP = new SoapClient("http://$sys_mantisbt_host/api/soap/mantisconnect.php?wsdl", array('trace'=>true, 'exceptions'=>true));
+$clientSOAP = new SoapClient("http://".forge_get_config('server','mantisbt')."/api/soap/mantisconnect.php?wsdl", array('trace'=>true, 'exceptions'=>true));
 $defect = $clientSOAP->__soapCall('mc_issue_get', array("username" => $username, "password" => $password, "issue_id" => $idBug));
 if ($defect->category != $_POST['categorie']){
 	$defect->category = $_POST['categorie'];

Modified: trunk/src/plugins/mantisbt/action/updateNote.php
===================================================================
--- trunk/src/plugins/mantisbt/action/updateNote.php	2010-09-17 12:42:34 UTC (rev 10531)
+++ trunk/src/plugins/mantisbt/action/updateNote.php	2010-09-17 12:57:42 UTC (rev 10532)
@@ -22,7 +22,7 @@
  */
 
 $noteEdit;
-$clientSOAP = new SoapClient("http://$sys_mantisbt_host/api/soap/mantisconnect.php?wsdl", array('trace'=>true, 'exceptions'=>true));
+$clientSOAP = new SoapClient("http://".forge_get_config('server','mantisbt')."/api/soap/mantisconnect.php?wsdl", array('trace'=>true, 'exceptions'=>true));
 $defect = $clientSOAP->__soapCall('mc_issue_get', array("username" => $username, "password" => $password, "issue_id" => $idBug));
 foreach($defect->notes as $key => $note){
 	if ($note->id == $idNote){

Modified: trunk/src/plugins/mantisbt/controler/filter.php
===================================================================
--- trunk/src/plugins/mantisbt/controler/filter.php	2010-09-17 12:42:34 UTC (rev 10531)
+++ trunk/src/plugins/mantisbt/controler/filter.php	2010-09-17 12:57:42 UTC (rev 10532)
@@ -25,128 +25,142 @@
 $bugfilter = array ();
 $bugfilter['_view_type'] = "advanced";
 
-if ( $_POST['sort'] ) {
+if ( isset($_POST['sort']) ) {
     $bugfilter['sort'] = $_POST['sort'];
 } else {
     $bugfilter['sort'] = "last_updated";
 }
-if ( $_POST['dir'] ) {
+if ( isset($_POST['dir']) ) {
     $bugfilter['dir'] = $_POST['dir'];
 } else {
     $bugfilter['dir'] = "DESC";
 }
 echo    '<form name="viewissues" id="mainform" method="post" action="?type='.$type.'&id='.$id.'&pluginname=mantisbt">';
-if ( $_POST['sort'] ) {
+if ( isset($_POST['sort']) ) {
     echo '<input type="hidden" name="sort" value="'.$_POST['sort'].'" />';
 }
-if ( $_POST['dir'] ) {
+if ( isset($_POST['dir']) ) {
     echo '<input type="hidden" name="dir" value="'.$_POST['dir'].'" />';
 }
 echo    '<div>';
-$listStatus= $clientSOAP->__soapCall('mc_enum_status', array("username" => $username, "password" => $password));
+try {
+    $listStatus= $clientSOAP->__soapCall('mc_enum_status', array("username" => $username, "password" => $password));
+} catch (SoapFault $soapFault) {
+    echo    '<div class="warning" >Un problème est survenu lors de la r&eacute;cup&eacute;ration des donn&eacute;es : '.$soapFault->faultstring.'</div>';
+    $errorPage = true;
+}
     
-echo "<div style='float: left;margin-right: 10px; width: 160px'>";
-echo "<h4 style='border-bottom: 1px solid #DAE0EA'>avec les status :</h3>";
+if (!isset($errorPage)) {
+    echo "<div style='float: left;margin-right: 10px; width: 160px'>";
+    echo "<h4 style='border-bottom: 1px solid #DAE0EA'>avec les status :</h3>";
     
-echo '<select name="projectStatus[]" id="projectStatus" multiple size="'.sizeof($listStatus).'" style="width: 160px; height: 100px">';
-foreach ($listStatus as $key => $status){
-    echo '<option value="'.$status->id.'"';
-    if (isset($_POST['projectStatus'])) {
-            $flipped_projectStatus = array_flip($_POST['projectStatus']); 
-            if (isset($flipped_projectStatus[$status->id])) {
-                echo 'selected="selected"';
-            }
+    echo '<select name="projectStatus[]" id="projectStatus" multiple size="'.sizeof($listStatus).'" style="width: 160px; height: 100px">';
+    foreach ($listStatus as $key => $status){
+        echo '<option value="'.$status->id.'"';
+        if (isset($_POST['projectStatus'])) {
+                $flipped_projectStatus = array_flip($_POST['projectStatus']); 
+                if (isset($flipped_projectStatus[$status->id])) {
+                    echo 'selected="selected"';
+                }
+        }
+        echo '>'.$status->name.'</option>';
     }
-    echo '>'.$status->name.'</option>';
-}
-echo '</select>';
-echo '</div>';
+    echo '</select>';
+    echo '</div>';
 
 if ($type == "group"){
     $bugfilter['project_id'][] = $idProjetMantis;
-    $listChild = $clientSOAP->__soapCall('mc_project_get_subprojects', array("username" => $username, "password" => $password, "project_id" => $idProjetMantis));
-    $mantisbtMembers =  $clientSOAP->__soapCall('mc_project_get_users', array("username" => $username, "password" => $password, "project_id" => $idProjetMantis, "access" => "ANYBODY"));
-    if ( 0 != sizeof($listChild) ) {
-        echo '<div style="float: left; margin-right: 10px; width: 160px">';    
-        echo '<h4 style="border-bottom: 1px solid #DAE0EA">Inclure les sous-projets :</h3>';
+    try {
+        $listChild = $clientSOAP->__soapCall('mc_project_get_subprojects', array("username" => $username, "password" => $password, "project_id" => $idProjetMantis));
+        $mantisbtMembers =  $clientSOAP->__soapCall('mc_project_get_users', array("username" => $username, "password" => $password, "project_id" => $idProjetMantis, "access" => "ANYBODY"));
+    } catch (SoapFault $soapFault) {
+        echo    '<div class="warning" >Un problème est survenu lors de la r&eacute;cup&eacute;ration des donn&eacute;es : '.$soapFault->faultstring.'</div>';
+        $errorPage = true;
+    }
 
-        echo '<select name="projectChildId[]" id="projectChildId" multiple style="width: 160px; height: 100px">';
-        foreach ( $listChild as $key => $child ) {
-            // on en profite pour récupérer tous les membres de tous les projets
-            $mantisbtMembersChild =  $clientSOAP->__soapCall('mc_project_get_users', array("username" => $username, "password" => $password, "project_id" => $child, "access" => "ANYBODY"));
-            foreach ( $mantisbtMembersChild as $key => $mantisbtMemberChild ) {
-                $found = 0;
-                foreach ($mantisbtMembers as $key => $mantisbtMember ) {
-                    if ( $mantisbtMemberChild->id == $mantisbtMember->id )
-                        $found = 1;
+    if (!isset($errorPage)) {
+        if ( 0 != sizeof($listChild) ) {
+            echo '<div style="float: left; margin-right: 10px; width: 160px">';    
+            echo '<h4 style="border-bottom: 1px solid #DAE0EA">Inclure les sous-projets :</h3>';
+
+            echo '<select name="projectChildId[]" id="projectChildId" multiple style="width: 160px; height: 100px">';
+            foreach ( $listChild as $key => $child ) {
+                // on en profite pour récupérer tous les membres de tous les projets
+                $mantisbtMembersChild =  $clientSOAP->__soapCall('mc_project_get_users', array("username" => $username, "password" => $password, "project_id" => $child, "access" => "ANYBODY"));
+                foreach ( $mantisbtMembersChild as $key => $mantisbtMemberChild ) {
+                    $found = 0;
+                    foreach ($mantisbtMembers as $key => $mantisbtMember ) {
+                        if ( $mantisbtMemberChild->id == $mantisbtMember->id )
+                            $found = 1;
+                    }
+                    if ( !$found) 
+                        $mantisbtMembers[] = $mantisbtMemberChild;
                 }
-                if ( !$found) 
-                    $mantisbtMembers[] = $mantisbtMemberChild;
+                $resultGroupNameFusionForge = db_query_params ('select groups.group_name from groups,group_mantisbt where groups.group_id = group_mantisbt.id_group and group_mantisbt.id_mantisbt = $1',
+                                                    array($child));
+                $rowGroupNameFusionForge = db_fetch_array($resultGroupNameFusionForge);
+                echo '<option value="'.$child.'"';
+                if (isset($_POST['projectChildId'])) {
+                    $flipped_projectChildId = array_flip($_POST['projectChildId']); 
+                    if (isset($flipped_projectChildId[$child])) {
+                        echo 'selected="selected"';
+                    }
+                }
+                echo '>'.$rowGroupNameFusionForge['group_name'].'</option>';
             }
-            $resultGroupNameFusionForge = db_query_params ('select groups.group_name from groups,group_mantisbt where groups.group_id = group_mantisbt.id_group and group_mantisbt.id_mantisbt = $1',
-                                                array($child));
-            $rowGroupNameFusionForge =& db_fetch_array($resultGroupNameFusionForge);
-            echo '<option value="'.$child.'"';
-            if (isset($_POST['projectChildId'])) {
-                $flipped_projectChildId = array_flip($_POST['projectChildId']); 
-                if (isset($flipped_projectChildId[$child])) {
+            echo '</select>';
+            echo '</div>';
+        }
+        echo '<div style="float: left; margin-right: 10px; width: 160px">';
+        echo '<h4 style="border-bottom: 1px solid #DAE0EA">rapport&eacute; par :</h3>';
+        echo '<select name="projectReporters[]" id="projectReporters" multiple style="width: 160px; height: 100px">';
+        foreach ($mantisbtMembers as $key => $mantisbtMember ) {
+            echo '<option value="'.$mantisbtMember->id.'"';
+            if (isset($_POST['projectReporters'])) {
+                $flipped_projectReporters = array_flip($_POST['projectReporters']);
+                if (isset($flipped_projectReporters[$mantisbtMember->id])) {
                     echo 'selected="selected"';
                 }
             }
-            echo '>'.$rowGroupNameFusionForge['group_name'].'</option>';
+            echo '>'.htmlspecialchars($mantisbtMember->real_name,ENT_QUOTES).'</option>';
         }
         echo '</select>';
         echo '</div>';
-    }
-    echo '<div style="float: left; margin-right: 10px; width: 160px">';
-    echo '<h4 style="border-bottom: 1px solid #DAE0EA">rapport&eacute; par :</h3>';
-    echo '<select name="projectReporters[]" id="projectReporters" multiple style="width: 160px; height: 100px">';
-    foreach ($mantisbtMembers as $key => $mantisbtMember ) {
-        echo '<option value="'.$mantisbtMember->id.'"';
-        if (isset($_POST['projectReporters'])) {
-            $flipped_projectReporters = array_flip($_POST['projectReporters']);
-            if (isset($flipped_projectReporters[$mantisbtMember->id])) {
-                echo 'selected="selected"';
+
+        echo '<div style="float: left; margin-right: 10px; width: 160px">';
+        echo '<h4 style="border-bottom: 1px solid #DAE0EA">attribu&eacute; &agrave; :</h3>';
+        echo '<select name="projectFixers[]" id="projectFixers" multiple style="width: 160px; height: 100px">';
+        foreach ($mantisbtMembers as $key => $mantisbtMember ) {
+            echo '<option value="'.$mantisbtMember->id.'"';
+            if (isset($_POST['projectFixers'])) {
+                $flipped_projectFixers = array_flip($_POST['projectFixers']);
+                if (isset($flipped_projectFixers[$mantisbtMember->id])) {
+                    echo 'selected="selected"';
+                }
             }
+            echo '>'.htmlspecialchars($mantisbtMember->real_name,ENT_QUOTES).'</option>';
         }
-        echo '>'.htmlspecialchars($mantisbtMember->real_name,ENT_QUOTES).'</option>';
-    }
-    echo '</select>';
-    echo '</div>';
+        echo '</select>';
+        echo '</div>';
 
-    echo '<div style="float: left; margin-right: 10px; width: 160px">';
-    echo '<h4 style="border-bottom: 1px solid #DAE0EA">attribu&eacute; &agrave; :</h3>';
-    echo '<select name="projectFixers[]" id="projectFixers" multiple style="width: 160px; height: 100px">';
-    foreach ($mantisbtMembers as $key => $mantisbtMember ) {
-        echo '<option value="'.$mantisbtMember->id.'"';
-        if (isset($_POST['projectFixers'])) {
-            $flipped_projectFixers = array_flip($_POST['projectFixers']);
-            if (isset($flipped_projectFixers[$mantisbtMember->id])) {
-                echo 'selected="selected"';
+        if ( $_POST['projectChildId'] ) {
+            foreach ( $_POST['projectChildId'] as $key => $child ) {
+                $bugfilter['project_id'][] = $child;
             }
         }
-        echo '>'.htmlspecialchars($mantisbtMember->real_name,ENT_QUOTES).'</option>';
-    }
-    echo '</select>';
-    echo '</div>';
 
-    if ( $_POST['projectChildId'] ) {
-        foreach ( $_POST['projectChildId'] as $key => $child ) {
-            $bugfilter['project_id'][] = $child;
+        if ( $_POST['projectReporters'] ) {
+            foreach ( $_POST['projectReporters'] as $key => $projectReporter ) {
+                $bugfilter['reporter_id'][] = $projectReporter;
+            }
         }
-    }
 
-    if ( $_POST['projectReporters'] ) {
-        foreach ( $_POST['projectReporters'] as $key => $projectReporter ) {
-            $bugfilter['reporter_id'][] = $projectReporter;
+        if ( $_POST['projectFixers'] ) {
+            foreach ( $_POST['projectFixers'] as $key => $projectFixer ) {
+                $bugfilter['handler_id'][] = $projectFixer;
+            }
         }
     }
-
-    if ( $_POST['projectFixers'] ) {
-        foreach ( $_POST['projectFixers'] as $key => $projectFixer ) {
-            $bugfilter['handler_id'][] = $projectFixer;
-        }
-    }
 }
 if ( $_POST['projectStatus'] ) {
     foreach ( $_POST['projectStatus'] as $key => $statusId ) {
@@ -180,4 +194,5 @@
      '<input type="submit" value="Appliquer le filtre" /></div>';
 echo '</form>';
 
+}
 ?>

Modified: trunk/src/plugins/mantisbt/view/addIssue.php
===================================================================
--- trunk/src/plugins/mantisbt/view/addIssue.php	2010-09-17 12:42:34 UTC (rev 10531)
+++ trunk/src/plugins/mantisbt/view/addIssue.php	2010-09-17 12:57:42 UTC (rev 10532)
@@ -41,7 +41,7 @@
 try {
     /* do not recreate $clientSOAP object if already created by other pages */
     if (!isset($clientSOAP))
-        $clientSOAP = new SoapClient("http://$sys_mantisbt_host/api/soap/mantisconnect.php?wsdl", array('trace'=>true, 'exceptions'=>true));
+        $clientSOAP = new SoapClient("http://".forge_get_config('server','mantisbt')."/api/soap/mantisconnect.php?wsdl", array('trace'=>true, 'exceptions'=>true));
 
     $listCategories = $clientSOAP->__soapCall('mc_project_get_categories', array("username" => $username, "password" => $password, "project_id" => $idProjetMantis));
     $listSeverities = $clientSOAP->__soapCall('mc_enum_severities', array("username" => $username, "password" => $password));
@@ -53,13 +53,11 @@
     $listStatus= $clientSOAP->__soapCall('mc_enum_status', array("username" => $username, "password" => $password));
     $listVersions = $clientSOAP->__soapCall('mc_project_get_versions', array("username" => $username, "password" => $password, "project_id" => $idProjetMantis));
 } catch (SoapFault $soapFault) {
-        $msg = $soapFault->faultstring;
-        $errorPage = true;
+    echo    '<div class="warning" >Un probl&egrave;me est survenu lors de la r&eacute;cup&eacute;ration des donn&eacute;es : '.$soapFault->faultstring.'</div>';
+    $errorPage = true;
 }
 
-if ($errorPage){
-    echo    '<div class="warning" >Un probl&egrave;me est survenu lors de la r&eacute;cup&eacute;ration des donn&eacute;es : '.$msg.'</div>';
-} else {
+if (!isset($errorPage)){
     echo 	'<form name="issue" method="POST" action="?type='.$type.'&id='.$id.'&pluginname='.$pluginname.'&idBug='.$defect->id.'&action=addIssue" >';
     echo	'<table class="innertabs">';
     echo		'<tr>';

Modified: trunk/src/plugins/mantisbt/view/addOrEditNote.php
===================================================================
--- trunk/src/plugins/mantisbt/view/addOrEditNote.php	2010-09-17 12:42:34 UTC (rev 10531)
+++ trunk/src/plugins/mantisbt/view/addOrEditNote.php	2010-09-17 12:57:42 UTC (rev 10532)
@@ -26,7 +26,7 @@
 try {
     /* do not recreate $clientSOAP object if already created by other pages */
     if (!isset($clientSOAP))
-        $clientSOAP = new SoapClient("http://$sys_mantisbt_host/api/soap/mantisconnect.php?wsdl", array('trace'=>true, 'exceptions'=>true));
+        $clientSOAP = new SoapClient("http://".forget_get_config('server','mantisbt')."/api/soap/mantisconnect.php?wsdl", array('trace'=>true, 'exceptions'=>true));
 
     $defect = $clientSOAP->__soapCall('mc_issue_get', array("username" => $username, "password" => $password, "issue_id" => $idBug));
     if ($view == "editNote"){

Modified: trunk/src/plugins/mantisbt/view/admin/StatPerStatus.php
===================================================================
--- trunk/src/plugins/mantisbt/view/admin/StatPerStatus.php	2010-09-17 12:42:34 UTC (rev 10531)
+++ trunk/src/plugins/mantisbt/view/admin/StatPerStatus.php	2010-09-17 12:57:42 UTC (rev 10532)
@@ -27,18 +27,15 @@
 try {
     /* do not recreate $clientSOAP object if already created by other pages */
     if (!isset($clientSOAP))
-        $clientSOAP = new SoapClient("http://$sys_mantisbt_host/api/soap/mantisconnect.php?wsdl", array('trace'=>true, 'exceptions'=>true));
+        $clientSOAP = new SoapClient("http://".forge_get_config('server','mantisbt')."/api/soap/mantisconnect.php?wsdl", array('trace'=>true, 'exceptions'=>true));
 
     $stats = $clientSOAP->__soapCall('mc_project_get_statistiques', array("username" => $username, "password" => $password, "project_id" => $idProjetMantis, "level" => 0));
 } catch (SoapFault $soapFault) {
-    echo $soapFault->faultstring;
-    echo "<br/>";
+    echo    '<div class="warning" >Un problème est survenu lors de la récupération des données : '.$soapFault->faultstring.'</div>';
     $errorPage = true;
 }
 
-if ($errorPage){
-    echo    '<div>Un problème est survenu lors de la récupération des données</div>';
-} else {
+if (!isset($errorPage)){
 $total = array('open' => 0, 'resolved' => 0, 'resolved' => 0, 'closed' => 0 , 'total' => 0);
 echo $HTML->boxTop("Répartition par état");
 echo    '<tr>';

Modified: trunk/src/plugins/mantisbt/view/admin/viewCategorie.php
===================================================================
--- trunk/src/plugins/mantisbt/view/admin/viewCategorie.php	2010-09-17 12:42:34 UTC (rev 10531)
+++ trunk/src/plugins/mantisbt/view/admin/viewCategorie.php	2010-09-17 12:57:42 UTC (rev 10532)
@@ -28,18 +28,15 @@
 try {
     /* do not recreate $clientSOAP object if already created by other pages */
     if (!isset($clientSOAP))
-        $clientSOAP = new SoapClient("http://$sys_mantisbt_host/api/soap/mantisconnect.php?wsdl", array('trace'=>true, 'exceptions'=>true));
+        $clientSOAP = new SoapClient("http://".forge_get_config('server','mantisbt')."/api/soap/mantisconnect.php?wsdl", array('trace'=>true, 'exceptions'=>true));
 
     $listCategories = $clientSOAP->__soapCall('mc_project_get_categories', array("username" => $username, "password" => $password, "project_id" => $idProjetMantis));
 } catch (SoapFault $soapFault) {
-    echo $soapFault->faultstring;
-    echo "<br/>";
+    echo    '<div class="warning" >Un problème est survenu lors de la récupération des données : '.$soapFault->faultstring.'</div>';
     $errorPage = true;
 }
 
-if ($errorPage){
-    echo    '<div>Un problème est survenu lors de la récupération des données</div>';
-} else {
+if (!isset($errorPage)){
     echo $HTML->boxTop('Gestion des categories');
     echo    '<table class="innertabs">';
     echo            '<tr>';

Modified: trunk/src/plugins/mantisbt/view/admin/viewVersion.php
===================================================================
--- trunk/src/plugins/mantisbt/view/admin/viewVersion.php	2010-09-17 12:42:34 UTC (rev 10531)
+++ trunk/src/plugins/mantisbt/view/admin/viewVersion.php	2010-09-17 12:57:42 UTC (rev 10532)
@@ -29,18 +29,15 @@
 try {
     /* do not recreate $clientSOAP object if already created by other pages */
     if (!isset($clientSOAP))
-        $clientSOAP = new SoapClient("http://$sys_mantisbt_host/api/soap/mantisconnect.php?wsdl", array('trace'=>true, 'exceptions'=>true));
+        $clientSOAP = new SoapClient("http://".forge_get_config('server','mantisbt')."/api/soap/mantisconnect.php?wsdl", array('trace'=>true, 'exceptions'=>true));
 
     $listVersions = $clientSOAP->__soapCall('mc_project_get_versions', array("username" => $username, "password" => $password, "project_id" => $idProjetMantis));
 } catch  (SoapFault $soapFault) {
-    echo $soapFault->faultstring;
-    echo "<br/>";
+    echo    '<div class="warning" >Un problème est survenu lors de la récupération des données : '.$soapFault->faultstring.'</div>';
     $errorPage = true;
 }
 
-if ($errorPage){
-    echo    '<div>Un problème est survenu lors de la récupération des données</div>';
-} else {
+if (!isset($errorPage)){
     echo $HTML->boxTop('Gestion des Versions');
     echo '<table class="innertabs">';
     echo	'<tr>';

Modified: trunk/src/plugins/mantisbt/view/editIssue.php
===================================================================
--- trunk/src/plugins/mantisbt/view/editIssue.php	2010-09-17 12:42:34 UTC (rev 10531)
+++ trunk/src/plugins/mantisbt/view/editIssue.php	2010-09-17 12:57:42 UTC (rev 10532)
@@ -41,7 +41,7 @@
 try {
     /* do not recreate $clientSOAP object if already created by other pages */
     if (!isset($clientSOAP))
-        $clientSOAP = new SoapClient("http://$sys_mantisbt_host/api/soap/mantisconnect.php?wsdl", array('trace'=>true, 'exceptions'=>true));
+        $clientSOAP = new SoapClient("http://".forge_get_config('server','mantisbt')."/api/soap/mantisconnect.php?wsdl", array('trace'=>true, 'exceptions'=>true));
 
     $defect = $clientSOAP->__soapCall('mc_issue_get', array("username" => $username, "password" => $password, "issue_id" => $idBug));
     $listCategories = $clientSOAP->__soapCall('mc_project_get_categories', array("username" => $username, "password" => $password, "project_id" => $defect->project->id));

Modified: trunk/src/plugins/mantisbt/view/roadmap.php
===================================================================
--- trunk/src/plugins/mantisbt/view/roadmap.php	2010-09-17 12:42:34 UTC (rev 10531)
+++ trunk/src/plugins/mantisbt/view/roadmap.php	2010-09-17 12:57:42 UTC (rev 10532)
@@ -25,19 +25,17 @@
 try {
     /* do not recreate $clientSOAP object if already created by other pages */
     if (!isset($clientSOAP))
-        $clientSOAP = new SoapClient("http://$sys_mantisbt_host/api/soap/mantisconnect.php?wsdl", array('trace'=>true, 'exceptions'=>true));
+        $clientSOAP = new SoapClient("http://".forge_get_config('server','mantisbt')."/api/soap/mantisconnect.php?wsdl", array('trace'=>true, 'exceptions'=>true));
 
+    $listChild = $clientSOAP->__soapCall('mc_project_get_subprojects', array("username" => $username, "password" => $password, "project_id" => $idProjetMantis));
+
 } catch (SoapFault $soapFault) {
-    echo $soapFault->faultstring;
-    echo "<br/>";
+    echo    '<div class="warning" >Un problème est survenu lors de la r&eacute;cup&eacute;ration des donn&eacute;es : '.$soapFault->faultstring.'</div>';
     $errorPage = true;
 }
 
-if ($errorPage) {
-    echo    '<div>Un problème est survenu lors de la r&eacute;cup&eacute;ration des donn&eacute;es</div>';
-} else {
+if (!isset($errorPage)) {
     GLOBAL $HTML;
-    $listChild = $clientSOAP->__soapCall('mc_project_get_subprojects', array("username" => $username, "password" => $password, "project_id" => $idProjetMantis));
 
 ?>
 <script type="text/javascript">

Modified: trunk/src/plugins/mantisbt/view/viewAttachment.php
===================================================================
--- trunk/src/plugins/mantisbt/view/viewAttachment.php	2010-09-17 12:42:34 UTC (rev 10531)
+++ trunk/src/plugins/mantisbt/view/viewAttachment.php	2010-09-17 12:57:42 UTC (rev 10532)
@@ -25,7 +25,7 @@
 if (empty($msg)) {
     if (!isset($defect)){
 	    try{
-		    $clientSOAP = new SoapClient("http://$sys_mantisbt_host/api/soap/mantisconnect.php?wsdl", array('trace'=>true, 'exceptions'=>true));
+		    $clientSOAP = new SoapClient("http://".forge_get_config('server','mantisbt')."/api/soap/mantisconnect.php?wsdl", array('trace'=>true, 'exceptions'=>true));
 		    $defect = $clientSOAP->__soapCall('mc_issue_get', array("username" => $username, "password" => $password, "issue_id" => $idBug));
 	    }catch (SoapFault $soapFault) {
 		    $error_attachment = $soapFault->faultstring;

Modified: trunk/src/plugins/mantisbt/view/viewIssue.php
===================================================================
--- trunk/src/plugins/mantisbt/view/viewIssue.php	2010-09-17 12:42:34 UTC (rev 10531)
+++ trunk/src/plugins/mantisbt/view/viewIssue.php	2010-09-17 12:57:42 UTC (rev 10532)
@@ -26,7 +26,7 @@
 	try {
         /* do not recreate $clientSOAP object if already created by other pages */
         if (!isset($clientSOAP))
-		    $clientSOAP = new SoapClient("http://$sys_mantisbt_host/api/soap/mantisconnect.php?wsdl", array('trace'=>true, 'exceptions'=>true));
+		    $clientSOAP = new SoapClient("http://".forge_get_config('server','mantisbt')."/api/soap/mantisconnect.php?wsdl", array('trace'=>true, 'exceptions'=>true));
 
 		$defect = $clientSOAP->__soapCall('mc_issue_get', array("username" => $username, "password" => $password, "issue_id" => $idBug));
 	} catch (SoapFault $soapFault) {

Modified: trunk/src/plugins/mantisbt/view/viewIssues.php
===================================================================
--- trunk/src/plugins/mantisbt/view/viewIssues.php	2010-09-17 12:42:34 UTC (rev 10531)
+++ trunk/src/plugins/mantisbt/view/viewIssues.php	2010-09-17 12:57:42 UTC (rev 10532)
@@ -33,18 +33,14 @@
 try {
     /* do not recreate $clientSOAP object if already created by other pages */
     if (!isset($clientSOAP))
-        $clientSOAP = new SoapClient("http://$sys_mantisbt_host/api/soap/mantisconnect.php?wsdl", array('trace'=>true, 'exceptions'=>true));
+        $clientSOAP = new SoapClient("http://".forge_get_config('server','mantisbt')."/api/soap/mantisconnect.php?wsdl", array('trace'=>true, 'exceptions'=>true));
 
 } catch (SoapFault $soapFault) {
-	echo $soapFault->faultstring;
-	echo "<br/>";
+    echo    '<div class="warning" >Un problème est survenu lors de la r&eacute;cup&eacute;ration des donn&eacute;es : '.$soapFault->faultstring.'</div>';
 	$errorPage = true;
 }
 
-if ($errorPage) {
-    echo    '<div>Un problème est survenu lors de la r&eacute;cup&eacute;ration des donn&eacute;es</div>';
-} else {
-
+if (!isset($errorPage)) {
     echo "<h2 style='border-bottom: 1px solid black'>Filtres</h2>";
 ?>
 <style>
@@ -89,15 +85,22 @@
     ?>
 </div>
 <br/>
-    <?php
-    // recuperation des bugs
-    $listBug = array();
-	if ($type == "user"){
-		$idsBugAll = $clientSOAP->__soapCall('mc_issue_get_filtered_by_user', array("username" => $username, "password" => $password, "filter" => $bugfilter ));
-	} else if ($type == "group"){
-		$idsBugAll = $clientSOAP->__soapCall('mc_project_get_issue_headers', array("username" => $username, "password" => $password, "project_id" => $idProjetMantis,  "page_number" => -1, "per_page" => -1, "filter" => $bugfilter));
-	}
+<?php
+}
+// recuperation des bugs
+$listBug = array();
+try {
+    if ($type == "user"){
+        $idsBugAll = $clientSOAP->__soapCall('mc_issue_get_filtered_by_user', array("username" => $username, "password" => $password, "filter" => $bugfilter ));
+    } else if ($type == "group"){
+        $idsBugAll = $clientSOAP->__soapCall('mc_project_get_issue_headers', array("username" => $username, "password" => $password, "project_id" => $idProjetMantis,  "page_number" => -1, "per_page" => -1, "filter" => $bugfilter));
+    }
+} catch (SoapFault $soapFault) {
+	echo 	'<div class="warning">Un problème est survenu lors de la r&eacute;cup&eacute;ration des donn&eacute;es : '.$soapFault->faultstring.'</div>';
+    $errorPage = true;
+}
 
+if (!isset($errorPage)) {
 	$pageActuelle = getIntFromRequest('page');
 	if (empty($pageActuelle)) {
 		$pageActuelle = 1;
@@ -106,7 +109,7 @@
 	$nombreBugs = count ($idsBugAll);
 	$nombreDePages=ceil($nombreBugs/$bugPerPage);
 	// Si la valeur de $pageActuelle (le numéro de la page) est plus grande que $nombreDePages...
-	if($pageActuelle>$nombreDePages){
+	if($pageActuelle>$nombreDePages) {
 		$pageActuelle=$nombreDePages;
 	}
 	$indexMin = ($pageActuelle - 1) * $bugPerPage;
@@ -124,24 +127,19 @@
 				);
 	}
 
-	if(count($listBugAll) >0){
+	if(count($listBugAll) >0) {
 		foreach ($listBugAll as $key => $defect) {
 			if ( ($indexMin <= $key) && ($indexMax >= $key) ){
 				$listBug[] = $defect;
 			}
 		}
 	}
-}
 
-// affichage page
-$nbligne=0;
+    // affichage page
+    $nbligne=0;
+    $boxTitle = 'Tickets';
 
-$boxTitle = 'Tickets';
-
-echo "<h2 style='border-bottom: 1px solid black'>$boxTitle</h2>";
-if ($errorPage){
-	echo 	'<div>Un problème est survenu lors de la r&eacute;cup&eacute;ration des donn&eacute;es</div>';
-}else {
+    echo "<h2 style='border-bottom: 1px solid black'>$boxTitle</h2>";
 	$picto_haut = util_make_url('themes/gforge/images/picto_fleche_haut_marron.png');
 	$picto_bas = util_make_url('themes/gforge/images/picto_fleche_bas_marron.png');
 	$nbligne++;
@@ -153,7 +151,7 @@
 	echo			'<form name="filterprority" method="post" action="?type='.$type.'&id='.$id.'&pluginname=mantisbt">';
 	if ($bugfilter['sort'] == "priority" && $bugfilter['dir'] == "ASC") {
 		echo			'<input type=hidden name="dir" value="DESC"/>';
-	}else if ($bugfilter['sort'] == "priority" && $bugfilter['dir'] == "DESC") {
+	} else if ($bugfilter['sort'] == "priority" && $bugfilter['dir'] == "DESC") {
 		echo			'<input type="hidden" name="dir" value="ASC"/>';
 	}
 	if ( isset($bugfilter['show_status'])) {
@@ -168,9 +166,9 @@
 	}
 	echo				'<input type=hidden name="sort" value="priority" />';
 	echo				'<a class="DataLink" href="javascript:document.filterprority.submit();">P';
-	if ($bugfilter['sort'] == "priority" && $bugfilter['dir'] == "ASC" ){
+	if ($bugfilter['sort'] == "priority" && $bugfilter['dir'] == "ASC" ) {
 		echo				'<img src="'.$picto_haut.'">';
-	}else if ($bugfilter['sort'] == "priority" && $bugfilter['dir'] == "DESC" ) {
+	} else if ($bugfilter['sort'] == "priority" && $bugfilter['dir'] == "DESC" ) {
 		echo				'<img src="'.$picto_bas.'">';
 	}
 	echo 				'</a>';
@@ -181,7 +179,7 @@
 	echo			'<form name="filterid" method="post" action="?type='.$type.'&id='.$id.'&pluginname=mantisbt">';
 	if ($bugfilter['sort'] == "id" && $bugfilter['dir'] == "ASC") {
 		echo			'<input type=hidden name="dir" value="DESC"/>';
-	}else if ($bugfilter['sort'] == "id" && $bugfilter['dir'] == "DESC") {
+	} else if ($bugfilter['sort'] == "id" && $bugfilter['dir'] == "DESC") {
 		echo			'<input type="hidden" name="dir" value="ASC"/>';
 	}
 	if ( isset($bugfilter['show_status'])) {
@@ -196,7 +194,7 @@
 	}
 	echo				'<input type=hidden name="sort" value="id" />';
 	echo				'<a class="DataLink" href="javascript:document.filterid.submit();">ID';
-	if ($bugfilter['sort'] == "id" && $bugfilter['dir'] == "ASC" ){
+	if ($bugfilter['sort'] == "id" && $bugfilter['dir'] == "ASC" ) {
 		echo				'<img src="'.$picto_haut.'">';
 	}else if ($bugfilter['sort'] == "id" && $bugfilter['dir'] == "DESC" ) {
 		echo				'<img src="'.$picto_bas.'">';
@@ -538,3 +536,5 @@
 	}
 	echo 	'</div>';
 }
+
+?>

Modified: trunk/src/plugins/mantisbt/view/viewNote.php
===================================================================
--- trunk/src/plugins/mantisbt/view/viewNote.php	2010-09-17 12:42:34 UTC (rev 10531)
+++ trunk/src/plugins/mantisbt/view/viewNote.php	2010-09-17 12:57:42 UTC (rev 10532)
@@ -26,7 +26,7 @@
     if (!isset($defect)){
         /* do not recreate $clientSOAP object if already created by other pages */
         if (!isset($clientSOAP))
-	        $clientSOAP = new SoapClient("http://$sys_mantisbt_host/api/soap/mantisconnect.php?wsdl", array('trace'=>true, 'exceptions'=>true));
+	        $clientSOAP = new SoapClient("http://".forge_get_config('server','mantisbt')."/api/soap/mantisconnect.php?wsdl", array('trace'=>true, 'exceptions'=>true));
 
 	    $defect = $clientSOAP->__soapCall('mc_issue_get', array("username" => $username, "password" => $password, "issue_id" => $idBug));
     }

Modified: trunk/src/plugins/mantisbt/www/index.php
===================================================================
--- trunk/src/plugins/mantisbt/www/index.php	2010-09-17 12:42:34 UTC (rev 10531)
+++ trunk/src/plugins/mantisbt/www/index.php	2010-09-17 12:57:42 UTC (rev 10532)
@@ -1,5 +1,7 @@
 <?php
 /*
+ * MantisBT plugin
+ *
  * Copyright 2010, Capgemini
  * Author: Franck Villaume - Capgemini
  * Author: Fabien Dubois - Capgemini
@@ -22,14 +24,8 @@
  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
  */
 
-/*
- * MantisBT plugin
- *
- */
-
 require_once('../../env.inc.php');
 require_once $gfcommon.'include/pre.php';
-require_once $gfcommon.'ldap/ldapUtils.php';
 require_once $gfconfig.'plugins/mantisbt/config.php';
 
 // the header that displays for the user portion of the plugin
@@ -81,7 +77,8 @@
 $error_msg = htmlspecialchars(getStringFromRequest('error_msg'));
 $warning_msg = htmlspecialchars(getStringFromRequest('warning_msg'));
 
-$password = getPasswordFromLDAP($user);
+//$password = getPassword($user);
+$password = '';
 $username = $user->getUnixName();
 
 if (!$type) {




More information about the Fusionforge-commits mailing list