Exemplo n.º 1
0
 def getDotNetSession(self):
     """
     Use the Zenoss.net credentials associated with this user to log in to a
     Zenoss.net session.
     """
     session = DotNetCommunication.getDotNetSession(
                                     self.zenossNetUser,
                                     self.zenossNetPassword)
     return session
Exemplo n.º 2
0
    def getZnetProjectsList(self):
        """
        Return a list of the zenoss.net projects.
        """
        import json
        import Products.ZenUtils.DotNetCommunication as DotNetCommunication

        userSettings = self.dmd.ZenUsers.getUserSettings()
        session = DotNetCommunication.getDotNetSession(userSettings.zenossNetUser, userSettings.zenossNetPassword)
        projects = session.retrieve("projectList")
        projects = json.loads(projects)
        return projects
 def getZnetProjectsList(self):
     """
     Return a list of the zenoss.net projects.
     """
     import json
     import Products.ZenUtils.DotNetCommunication as DotNetCommunication
     userSettings = self.dmd.ZenUsers.getUserSettings()
     session = DotNetCommunication.getDotNetSession(
         userSettings.zenossNetUser, userSettings.zenossNetPassword)
     projects = session.retrieve('projectList')
     projects = json.loads(projects)
     return projects