Advertisement
cyid

remove relationship

Oct 7th, 2014
213
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.40 KB | None | 0 0
  1.     def remove(self, app, leaveObjects=False):
  2.         Device._relations = tuple(
  3.             [x for x in Device._relations if x[0] != '<componentname>'])
  4.  
  5.         self.rebuildRelations(app.zport.dmd)
  6.         super(ZenPack, self).remove(app, leaveObjects)
  7.  
  8.     def rebuildRelations(self, dmd):
  9.         for d in dmd.Devices.getSubDevices():
  10.             d.buildRelations()
  11.             d.os.buildRelations()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement