Salome HOME
PN bug notation scientifique
[tools/eficas.git] / Ihm / I_MCLIST.py
index 9bde6f8b700381a7dd4babe22532a24d493c1522..c9442374e5518b500a3d403a5a97913b9320b1ab 100644 (file)
@@ -1,3 +1,4 @@
+# -*- coding: utf-8 -*-
 #            CONFIGURATION MANAGEMENT OF EDF VERSION
 # ======================================================================
 # COPYRIGHT (C) 1991 - 2002  EDF R&D                  WWW.CODE-ASTER.ORG
@@ -46,11 +47,24 @@ class MCList:
       else:
         return 0
 
+  def isrepetable(self):
+    """
+       Indique si l'objet est répétable.
+       Retourne 1 si le mot-clé facteur self peut être répété
+       Retourne 0 dans le cas contraire
+    """
+    if self.data[0].definition.max > 1:
+       # marche avec '**'
+       return 1
+    else :
+       return 0
+
   def isoblig(self):
      """
      Une MCList n'est jamais obligatoire (même si le MCFACT qu'elle représente l'est
      """
-     return 0
+     return self.data[0].definition.statut=='o'
+     #return 0
 
   def liste_mc_presents(self):
     return []
@@ -123,6 +137,14 @@ class MCList:
     if self.parent:
       self.parent.init_modif()
 
+  def fin_modif(self):
+    """
+      Méthode appelée après qu'une modification a été faite afin de déclencher
+      d'éventuels traitements post-modification
+    """
+    if self.parent:
+      self.parent.fin_modif()
+
   def get_genealogie(self):
      """
          Retourne la liste des noms des ascendants.