Merci beaucoup pour votre aide.
Bon c& #039;est fait.
Voici le lien pour le package uniquement à l& #039;ancien format (.tar.gz) : importexport-0.0.3a1.tar.gz
J& #039;ai fait un rapide test :
- Mise à jour du status automatique
- Mise à jour de la date de soumission (uniquement au format jour/mois/année, si année < 100 alors convertit en 2000 si < 70 sinon 1900)
- Correction des deux warnings reportés dans le fil.
Vincent
Mantis: 1.1.0, 1.1.5, 1.1.1
PHP: 5.0.4
SQL: MySQL 5.0.19
OS: Linux
Please complete your signature with your environment informations.
Enable skype notification here
Bonjour,
Le statut et la date de soumission marchent parfaitement, mais maintenant j& #039;ai un problème sur tous les champs personnalisés. En effet ceux ci sont remplis avec des données qui n& #039;ont rien à voir avec ce qui est spécifié dans le xml, dés qu& #039;il y a un champ date ça écrit 30/11/1999 et pour les autres champs j& #039;obtiens 943916400. Je ne sais pas vraiment d& #039;où ça vient.
Bonjour,
Vous n& #039;avez pas mis de valeur par défaut pour vos champs personnalisés ?
Vincent
Mantis: 1.1.0, 1.1.5, 1.1.1
PHP: 5.0.4
SQL: MySQL 5.0.19
OS: Linux
Please complete your signature with your environment informations.
Enable skype notification here
Non je n& #039;en ai pas mise, parce qu& #039;il n& #039;est pas vraiment possible d& #039;en mettre. Mes champs sont par exemple des champs de date ou des chiffres à donner et je ne vois pas quel genre de valeur par défaut je pourrai mettre pour ce genre de champ
De plus les valeurs que j& #039;ai indiquées dans mon message précédent sont mises même lorsqu& #039;il y a une valeur d& #039;indiquée dans le xml, donc la valeur par défaut ne devrait pas être utlisée dans ces cas là.
J& #039;avoue que je suis un peu sec...
Pourriez vous ajouter dans le fichier plugins/importexport/core/print_api.php à la ligne 123 ceci : Language: PHP plugins_importexport_convert_custom_field( $p_value, $p_type ) {
&<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>;value = &<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>; . $p_value . &<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>;, type = &<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>; . $p_type . &<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>;<br />&<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>;;
( $p_type ) {
Refaites un essai avec un ou plusieurs bugs et poster ici le résultat, merci.
Vincent
Mantis: 1.1.0, 1.1.5, 1.1.1
PHP: 5.0.4
SQL: MySQL 5.0.19
OS: Linux
Please complete your signature with your environment informations.
Enable skype notification here
Excusez moi mais je ne comprends pas où je dois mettre ce début de fonction. A la ligne 123 du fichier que vous m& #039;avez indiqué se trouve ceci :
for( $i=0; $i < $t_rows; $i++ ) {
Ceci étant dans la fonction suivante :
function plugins_importexport_write_bug_rows( $p_rows, $t_columns ) {
Quote DoubleNoExcusez moi mais je ne comprends pas où je dois mettre ce début de fonction. A la ligne 123 du fichier que vous m& #039;avez indiqué se trouve ceci :
for( $i=0; $i < $t_rows; $i++ ) {
Ceci étant dans la fonction suivante :
function plugins_importexport_write_bug_rows( $p_rows, $t_columns ) {
Oups, c& #039;est dans le fichier bugs_api.php et non print_api.php.
Vincent
Mantis: 1.1.0, 1.1.5, 1.1.1
PHP: 5.0.4
SQL: MySQL 5.0.19
OS: Linux
Please complete your signature with your environment informations.
Enable skype notification here
OK je viens de le faire et voici ce que m& #039;annonce l& #039;étape 4 :
Quote
value = 31/01/2006, type = 8
value = , type = 9
value = , type = 9
value = , type = 9
value = , type = 9
value = , type = 9
value = , type = 9
value = , type = 0
value = , type = 0
value = , type = 6
value = , type = 0
value = , type = 2
value = , type = 8
value = 0, type = 2
value = 31/01/2006, type = 8
value = SO, type = 6
value = , type = 8
value = , type = 8
Ca y est j& #039;ai trouvé...
Vous pouvez retirer le echo et modifier la fonction juste au dessus (c& #039;est juste quelques lignes au dessus à la fin de la fonction) : Language: PHP helper_call_custom_function( &<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>;issue_create_validate&<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>;, array( $t_bug_data ) );
$t_related_custom_field_ids = custom_field_get_linked_ids( $t_bug_data->project_id );
( $t_related_custom_field_ids $t_id ) {
$t_def = custom_field_get_definition( $t_id );
$t_value = gpc_get_string( &<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>;custom_&<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>; . $p_ptr . &<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>;_&<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>; . $t_id, &<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>;&<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>; );
( $t_value != &<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>;&<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>; ) {
$t_value = plugins_importexport_convert_custom_field( $t_value, $t_def[&<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>;type&<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>;] );
}
( $t_def[&<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>;require_report&<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>;] && $t_value == &<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>;&<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>; ) {
;
}
( $t_value == &<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>;&<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>; ) {
$t_value = $t_def[&<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>;default_value&<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>;];
}
( !custom_field_validate( $t_id, $t_value ) ) {
;
}
}
$p_id = bug_create( $t_bug_data );
( $t_related_custom_field_ids $t_id ) {
( !custom_field_has_write_access( $t_id, $p_id ) ) {
;
}
$t_value = gpc_get_string( &<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>;custom_&<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>; . $p_ptr . &<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>;_&<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>; . $t_id, &<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>;&<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>; );
$t_def = custom_field_get_definition( $t_id );
( $t_value != &<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>;&<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>; ) {
$t_value = plugins_importexport_convert_custom_field( $t_value, $t_def[&<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>;type&<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>;] );
} {
$t_value = $t_def[&<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>;default_value&<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>;];
}
( !custom_field_set_value( $t_id, $p_id, $t_value ) ) {
;
}
}
email_new_bug( $p_id );
C& #039;est surtout dans le second foreach qu& #039;il y a des modifications.
Vincent
Mantis: 1.1.0, 1.1.5, 1.1.1
PHP: 5.0.4
SQL: MySQL 5.0.19
OS: Linux
Please complete your signature with your environment informations.
Enable skype notification here
Ca marche parfaitement. Merci.
Sinon pour les notes, vous aviez dit qu& #039;elles n& #039;étaient pas prises en compte c& #039;est bien ça?
Quote DoubleNoCa marche parfaitement. Merci.
Sinon pour les notes, vous aviez dit qu& #039;elles n& #039;étaient pas prises en compte c& #039;est bien ça?
Oui c& #039;est ça, il va falloir que le les ajoute (peut-être ce soir).
Vincent
Mantis: 1.1.0, 1.1.5, 1.1.1
PHP: 5.0.4
SQL: MySQL 5.0.19
OS: Linux
Please complete your signature with your environment informations.
Enable skype notification here
Ah c& #039;est cool ça merci.
Encore une question, pour le rapporteur du bogue, si dans le xml je lui mets l& #039;id d& #039;un utilisateur il le mettra en tant que rapporteur ou ce sera toujours moi le rapporteur?
Quote DoubleNoAh c& #039;est cool ça merci.
Encore une question, pour le rapporteur du bogue, si dans le xml je lui mets l& #039;id d& #039;un utilisateur il le mettra en tant que rapporteur ou ce sera toujours moi le rapporteur?
Si vous remplissez le champ reporter_id dans le XML il sera pris en compte (je pense qu& #039;il faut quand même que l& #039;utilisateur existe, mais je n& #039;en suis pas sûr).
Vincent
Mantis: 1.1.0, 1.1.5, 1.1.1
PHP: 5.0.4
SQL: MySQL 5.0.19
OS: Linux
Please complete your signature with your environment informations.
Enable skype notification here
D& #039;accord. Donc il ne manque plus que le traitement des notes et l& #039;import sera parfait
Je vous remercie d& #039;avoir pris le temps de m& #039;aider pour tous mes problèmes.
Quote DoubleNoD& #039;accord. Donc il ne manque plus que le traitement des notes et l& #039;import sera parfait
Je vous remercie d& #039;avoir pris le temps de m& #039;aider pour tous mes problèmes.
Il n& #039;y a pas de quoi, merci d& #039;avoir été béta testeur
Vincent
Mantis: 1.1.0, 1.1.5, 1.1.1
PHP: 5.0.4
SQL: MySQL 5.0.19
OS: Linux
Please complete your signature with your environment informations.
Enable skype notification here
bonjour.
excusez de m& #039;incruster dans votre discussion.
j& #039;ai lu tous les echanges qui vous avez eus (deboutv, DoubleNo). j& #039;ai donc installé le dernier pluginmanager, j& #039;ai enlevé la ligne require(xx_lang_inc) dans custom_strings_inc). à l& #039;etape 2 de l& #039;import j& #039;ai chargé un fichier xml que j& #039;ai exporté grace au plugin import export. par contre à l& #039;etape 3 (Etape 3 / 4: Sélectioner les bugs à importer), il n& #039;y a rien qui s& #039;affiche. est ce que j& #039;ai raté une etape de la discussion?
Quote joejoebonjour.
excusez de m& #039;incruster dans votre discussion.
Y a pas de mal
Quote
j& #039;ai lu tous les echanges qui vous avez eus (deboutv, DoubleNo). j& #039;ai donc installé le dernier pluginmanager, j& #039;ai enlevé la ligne require(xx_lang_inc) dans custom_strings_inc). à l& #039;etape 2 de l& #039;import j& #039;ai chargé un fichier xml que j& #039;ai exporté grace au plugin import export. par contre à l& #039;etape 3 (Etape 3 / 4: Sélectioner les bugs à importer), il n& #039;y a rien qui s& #039;affiche. est ce que j& #039;ai raté une etape de la discussion?
Vous utilisez quelles versions de Mantis, Plugin Manager (à priori 0.1.0 si j& #039;ai bien compris) et Import/Export ?
Vincent
Mantis: 1.1.0, 1.1.5, 1.1.1
PHP: 5.0.4
SQL: MySQL 5.0.19
OS: Linux
Please complete your signature with your environment informations.
Enable skype notification here
mantis 1.0.5
importexport-0.0.3a1
pluginmanager-0.1.0
Quand vous dites qu& #039;il n& #039;y a rien qu& #039;y s& #039;affiche, il y a bien les boutons suivants/précedents (mais aucun bug listé) ?
Vincent
Mantis: 1.1.0, 1.1.5, 1.1.1
PHP: 5.0.4
SQL: MySQL 5.0.19
OS: Linux
Please complete your signature with your environment informations.
Enable skype notification here
aucun bug n& #039;est listé.
par contre j& #039;ai bien les boutons suivants et precedents
A priori il doit y avoir un problème lors de la lecture du fichier importé.
Est-ce que vous pouvez modifier le fichier plugins/importexport/core/xml_api.php à la fin : Language: PHP plugins_importexport_xml_parse( $p_filename ) {
$t_result;
$t_result =();
$t_parser =( &<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>;&<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>; );
( $t_parser, &<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>;StartElement&<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>;, &<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>;EndElement&<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>; );
( $t_parser, &<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>;CharacterData&<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>; );
( !( $fp =( $p_filename, &<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>;r&<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>;) ) ) {
&<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>;Erreur d\&<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>;ouverture du fichier : &<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>; . $p_filename;
$t_result;
}
$t_data =( $fp,( $p_filename ) );
( $fp );
( ( $t_parser, $t_data, ) ) {
&<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>;Erreur d\&<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>;analyse du fichier&<a href="http://bugtracker.morinie.fr/mantis/view.php?id=039" target="_blank">#039</a>;;
();
}
( $t_parser );
$t_result;
}
Vincent
Mantis: 1.1.0, 1.1.5, 1.1.1
PHP: 5.0.4
SQL: MySQL 5.0.19
OS: Linux
Please complete your signature with your environment informations.
Enable skype notification here
Edited 1 time(s). Last edit at 05/31/2007 12:20PM by deboutv.
il affiche (Erreur d& #039;analyse du fichier)
Est-ce que vous pouvez m& #039;envoyer le fichier XML (remplacez éventuellement les données confidentielles) ?
Vincent
Mantis: 1.1.0, 1.1.5, 1.1.1
PHP: 5.0.4
SQL: MySQL 5.0.19
OS: Linux
Please complete your signature with your environment informations.
Enable skype notification here
j& #039;ai rajouté echo & #039;Erreur d\& #039;analyse du fichier& #039;. $p_filename; et il va lire dans C:\PROGRA~1\EASYPH~1\\tmp\php1134.tmp
ce n& #039;est pas l& #039;emplacement de mon fichier. je ne sais pas si c& #039;est à l& #039;origine de l& #039;erreur ou pas
Online Users
Guests:
6
Record Number of Users:
1
on April 02, 2023
Record Number of Guests:
115
on November 09, 2023
Top Users
|