Identify objects (Site/Slice/Person) created through SFA using sfa_created tag
[plcapi.git] / PLC / Accessors / Accessors_standard.py
index 0a02d8a..55ff66e 100644 (file)
@@ -68,12 +68,8 @@ define_accessors(current_module, Node, "Extensions", "extensions",
                  "node/config", "space-separated list of extensions to install",
                  set_roles=["admin"],expose_in_api=True)
 # access HRN - this is the ideal definition of roles, even if AddNodeTag cannot handle this
-define_accessors(current_module, Node, "Hrn","hrn",
-                 "node/person/sfa", "SFA human readable name",
-                 set_roles=all_roles, expose_in_api=True)
-# same for persons
-define_accessors(current_module, Person, "Hrn","hrn",
-                 "node/person/sfa", "SFA human readable name",
+define_accessors(current_module, [Node,Person,Slice,Site] , "Hrn", "hrn",
+                 "node/person/slice/site/sfa", "SFA human readable name",
                  set_roles=all_roles, expose_in_api=True)
 
 # test nodes perform their installation from an uncompressed bootstrapfs
@@ -112,3 +108,8 @@ define_accessors(current_module, Interface, "Alias", "alias",
 define_accessors(current_module, Interface, "Backdoor", "backdoor",
                  "interface/hidden", "For testing new settings",
                  set_roles=admin_roles)
+
+# we need to identify objects created through SFA interfaces
+define_accessors(current_module, [Person,Slice,Site] , "SfaCreated", "sfa_created",
+                 "person/slice/site/sfa", "Tag objects created through SFA interfaces",
+                 set_roles=all_roles, expose_in_api=True)