Added idProject property to ensemble node in ldt xml when ensemble node is created via LdtAnnotation object
authordurandn
Thu, 03 Sep 2015 18:02:53 +0200
changeset 1423 09d4840f213e
parent 1422 337fb3ff4e18
child 1424 bcd4df4ddd69
Added idProject property to ensemble node in ldt xml when ensemble node is created via LdtAnnotation object
src/ldt/ldt/ldt_utils/utils.py
--- a/src/ldt/ldt/ldt_utils/utils.py	Thu Sep 03 12:29:51 2015 +0200
+++ b/src/ldt/ldt/ldt_utils/utils.py	Thu Sep 03 18:02:53 2015 +0200
@@ -275,6 +275,7 @@
             path_ensemble.set('title', _('Personal cutting'))
             path_ensemble.set('author', 'IRI')
             path_ensemble.set('abstract', 'IRI')
+            path_ensemble.set('idProject', self.project.ldt_id)
             path_ensemble = [path_ensemble]
         #else:
         #    path_ensemble = path_content[0].xpath('ensemble')
@@ -379,7 +380,7 @@
         self.update_annotation_element(element, title, text, begin, dur, author, date, color, audio_src, audio_href, tags_list)
            
         return ensemble_id
-    
+        
     def save(self, must_reindex=True):
         if self.to_add:
             self.project.ldt = lxml.etree.tostring(self.ldtdoc, pretty_print=True)