def dict(self): response = getDict(self) del response['stripeToken'] del response['privateKey'] del response['password'] del response['salt'] return response
def toDict(self): response = getDict(self) try: response['start'] = int(self.start) except: pass #hANDLE DATE TYPE response['source'] = str(self.source.id) return response
def dict(self): response = getDict(self) del response['client'] del response['credentials'] # del response['schemaOverRide'] response['schema'] = SourceHandler.getSchema(clientID=str( self.client.id), sourceID=str(self.id)) # response['schema'].update(self.schemaOverRide) return response
def dict(self): response = getDict(self) try: response['query']['source'] = response['query']['source']['id'] except: pass del response['client'] response['id'] = "graph_" + str(self.id) return response
def getTemplate(cls): empty = cls( id='create', type='line', name=random.choice(defaultGraphNames), data=Data(), grid=Grid(), crossHair=CrossHair(), legend=Legend(), tooltips=Tooltips(), query=Query(), incrementSelector=IncrementSelector(), rangeSelector=RangeSelector(), limits=[], exportData=ExportData(), ) empty = getDict(empty) del empty['client'] return empty
def toDict(self): return getDict(self)
def dict(self): return getDict(self)