Ajout relation charge/mo
authorAlicia FLOREZ <alicflorez@gmail.com>
Fri, 12 Apr 2013 13:34:34 +0000 (15:34 +0200)
committerAlicia FLOREZ <alicflorez@gmail.com>
Fri, 12 Apr 2013 13:34:34 +0000 (15:34 +0200)
projet.py
views/projet.xml

index 7dd301c..a217e23 100644 (file)
--- a/projet.py
+++ b/projet.py
@@ -219,6 +219,8 @@ class Charge(osv.Model):
         "evolution_id": fields.many2one("projet.evolution",
                                     string="Evolution",
                                     required=True),
+        "mo_id": fields.many2one("projet.mo",
+                                 string="Mo"),
     }
 
 class mo(osv.Model):
@@ -230,6 +232,9 @@ class mo(osv.Model):
         "name": fields.char(string="Title"),
         "description": fields.text(string="Description"),
         "chose": fields.selection(_choses, string="Chose", required=True),
+        "charges": fields.one2many("projet.charge",
+                                   "mo_id",
+                                   string="Charges"),
     }
 
     _defaults = {
index 58a562b..112e87f 100644 (file)
                             <page string="Chantiers">
                                 <field name="chantiers" />
                             </page>
+                            <page string="Paliers">
+                                <field name="paliers" />
+                            </page>
+                            <page string="Phases">
+                                <field name="phases" />
+                            </page>
                         </notebook>
                     </sheet>
                 </form>