def changeAsset(self, idAsset): lastPrice = Asset.getLastPrice(self, idAsset) newLastPrice = DBUpdater.randPrice(self, lastPrice) change = Asset.getChange(self, idAsset) newChange = DBUpdater.randChange(self, change) changePercentage = Asset.getChangePercentage(self, idAsset) newChangePercentage = DBUpdater.randPercentage(self, changePercentage) volume = Asset.getVolume(self, idAsset) newVolume = DBUpdater.randVolume(self, volume) Asset.updateAsset(self, idAsset, newLastPrice, newChange, newChangePercentage, newVolume) Asset.notifyObservers(self, self.user, self.tkframe) return newLastPrice
def getVolume(self, idAtivo): return Asset.getVolume(self, idAtivo)
def getVolume(self, idContrato): assetId = self.getAssetId(idContrato) return Asset.getVolume(self, assetId)