(self, data)
return
Attempt to create a new model/table from a dict
Attempt to create a new model/table from a dict
Attempt to create a new model / table from a dict
def createfromDict(self, data):
        """Attempt to create a new model/table from a dict"""

        try:
            namefield=self.namefield
        except:
            namefield=data.keys()[0]
        self.model = TableModel()
        self.model.importDict(data, namefield=namefield)
        self.model.setSortOrder(0,reverse=self.reverseorder)
        return
def createfromDict ( self , data ) : try : namefield = self . namefield except : namefield = data . keys ( ) [ 0 ] self . model = TableModel ( ) self . model . importDict ( data , namefield = namefield ) self . model . setSortOrder ( 0 , reverse = self . reverseorder ) return