]> SALOME platform Git repositories - tools/eficas.git/commitdiff
Salome HOME
Pour prendre en compte tous les codes
authorPascale Noyret <pascale.noyret@edf.fr>
Mon, 1 Oct 2012 13:22:57 +0000 (13:22 +0000)
committerPascale Noyret <pascale.noyret@edf.fr>
Mon, 1 Oct 2012 13:22:57 +0000 (13:22 +0000)
voir bugtracker 2404

src/EFICASGUI/eficasSalome.py

index 9b19ba746dc504f1d1d7412b1415e837a5adf9cc..9e43529be2c3ddcbadc359d94d5fceb2a7d3ed15 100644 (file)
@@ -471,15 +471,30 @@ class MyEficas( qtEficas.Appli ):
             moduleEntry = self.editor.findOrCreateComponent(self.module, self.componentName)
             itemName    = re.split("/",jdcPath)[-1]
             
+            if folderName.has_key(self.code) :
+               monFolderName=folderName[ self.code ]
+            else :
+               monFolderName=str(self.code)+"Files"
+
+            if folderType.has_key(self.code) :
+               monFolderType=fileType[ self.code ]
+            else :
+               monFolderType=str(self.code)+"_FILE_FOLDER"
+
+            if fileType.has_key(self.code) :
+               monFileType=fileType[ self.code ]
+            else :
+               monFileType="FICHIER_EFICAS_"+str(self.code)
+
             fatherEntry = self.editor.findOrCreateItem(
                                     moduleEntry,
-                                    name = folderName[self.code],
+                                    name = monFolderName,
                                     #icon = "ICON_COMM_FOLDER",
-                                    fileType = folderType[self.code])
+                                    fileType = monFolderType)
                                                                         
             commEntry = self.editor.findOrCreateItem( fatherEntry ,
                                            name = itemName,
-                                           fileType = fileType[ self.code ],
+                                           fileType = monFileType,
                                            fileName = jdcPath,
                                            #icon    = "ICON_COMM_FILE",
                                            comment = str( jdcPath ))