This is an automated email from the git hooks/post-receive script. New commit to branch feature/1377-Amélioration_import_export_tous in repository lima. See https://gitlab.nuiton.org/chorem/lima.git commit 35044bc2f521a551db882d2cf1d1201913a1258c Author: David Cossé <cosse@codelutin.com> Date: Fri Dec 23 16:29:35 2016 +0100 refs #1377 la méthode générant le nom du fichier est autonome --- .../java/org/chorem/lima/ui/importexport/ImportExport.java | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/lima-swing/src/main/java/org/chorem/lima/ui/importexport/ImportExport.java b/lima-swing/src/main/java/org/chorem/lima/ui/importexport/ImportExport.java index fb3f64b..299fa6b 100644 --- a/lima-swing/src/main/java/org/chorem/lima/ui/importexport/ImportExport.java +++ b/lima-swing/src/main/java/org/chorem/lima/ui/importexport/ImportExport.java @@ -125,10 +125,12 @@ public class ImportExport { } private static String getSelectedFileWithExtension(ImportExportEnum export, String filePath) { - filePath = filePath == null ? "" : filePath.trim(); - filePath = filePath.endsWith("/") ? filePath + getExportDefaultFileName(export) : filePath; - String nameLower = (filePath.toLowerCase()); - filePath = nameLower.endsWith(CSV) ? filePath : filePath + CSV; + if (ImportExportEnum.CSV_ALL_EXPORT != export && !export.getImportMode()) { + filePath = filePath == null ? "" : filePath.trim(); + filePath = filePath.endsWith("/") ? filePath + getExportDefaultFileName(export) : filePath; + String nameLower = (filePath.toLowerCase()); + filePath = nameLower.endsWith(CSV) ? filePath : filePath + CSV; + } return filePath; } @@ -567,9 +569,7 @@ public class ImportExport { } if (chooser.showOpenDialog(viewComponent) == JFileChooser.APPROVE_OPTION) { filePath = chooser.getSelectedFile().getAbsolutePath(); - if (!importMode) { - filePath = getSelectedFileWithExtension(importExportMethod, filePath); - } + filePath = getSelectedFileWithExtension(importExportMethod, filePath); } return filePath; -- To stop receiving notification emails like this one, please contact chorem.org SCM administrator <admin+scm@chorem.org>.