[tracker] data-generators: Use affiliation for person contacts



commit 296a6fc559a6fb01c490dcbc8ddbc4592ab6b6b5
Author: Jürg Billeter <j bitron ch>
Date:   Tue Nov 16 14:51:44 2010 +0100

    data-generators: Use affiliation for person contacts

 utils/data-generators/cc/nco.py |   13 ++++++++-----
 1 files changed, 8 insertions(+), 5 deletions(-)
---
diff --git a/utils/data-generators/cc/nco.py b/utils/data-generators/cc/nco.py
index 0d0dbad..b7aebab 100644
--- a/utils/data-generators/cc/nco.py
+++ b/utils/data-generators/cc/nco.py
@@ -118,6 +118,12 @@ def generateContactIM(index):
 
 ####################################################################################
 nco_PersonContact = '''
+<%(contact_uri)s:home> a nco:Affiliation;
+    nco:hasEmailAddress      %(email_address_uri)s ;
+    nco:hasPhoneNumber       %(phonenumber_uri)s ;
+    nco:hasPostalAddress     %(postal_address_uri)s ;
+    nco:hasIMAddress         %(im_address_uri)s .
+
 <%(contact_uri)s> a nco:PersonContact;
     nco:fullname            "%(contact_name_given)s %(contact_name_family)s";
     nco:nameGiven           "%(contact_name_given)s";
@@ -130,12 +136,9 @@ nco_PersonContact = '''
     nco:gender               %(contact_gender)s ;
     nco:contactUID          "%(contact_uid)s" ;
     nco:note                "%(contact_note)s" ;
-    nco:hasEmailAddress      %(email_address_uri)s ;
-    nco:hasPhoneNumber       %(phonenumber_uri)s ;
-    nco:hasPostalAddress     %(postal_address_uri)s ;
-    nco:hasIMAddress         %(im_address_uri)s ;
     nie:contentCreated      "%(contact_created)s" ;
-    nie:contentLastModified "%(contact_modified)s"  .
+    nie:contentLastModified "%(contact_modified)s"  ;
+    nco:hasAffiliation      <%(contact_uri)s:home> .
 '''
 def generatePersonContact(index):
   me = 'nco#PersonContact'



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]