Logo Search packages:      
Sourcecode: pythoncard version File versions  Download package

def manilaaccount::ManilaAccount::manilaLogin (   self  ) 

Logs in to a Manila server.

Returns 1 on success, 0 on failure.

Definition at line 50 of file manilaaccount.py.

00050                          :
        """Logs in to a Manila server.

        Returns 1 on success, 0 on failure."""
        if (not self.checkSetupOK(1)):
            return 0

        if self.getPassword() == "":
            result = dialog.textEntryDialog(None, \
                                         'Please enter your Manila password (It will not be saved to the config): ',                                                              
                                         "Password entry...",
                                         '', wx.TE_PASSWORD)
            if not result.accepted:
                self.setErrorMessage("You must enter a password to continue.")
                return 0
            self.sessionPassword = result.text

        if not self.getLoggedIn():
            try:
                self.createManilaSite()
                
                self.settings["sitename"] = self.manilaSite.manila.getSiteName(self.prefs["siteurl"])
                self.storiesList = self.manilaSite.manila.message.listStories(self.prefs["username"], \
                                                                              self.getPassword(), \
                                                                              self.settings["sitename"])
                self.setLoggedIn(1)
            except xmlrpclib.Fault, e:
                self.sessionPassword = ""
                self.setErrorMessage("Error logging in: %s" % e.faultString)
                return 0
        else:
            self.setErrorMessage("Already logged in.")
            return 0
        return 1
            

    def manilaGetStoryList(self):


Generated by  Doxygen 1.6.0   Back to index