2022-05-29 14:03:17 +00:00
|
|
|
from __future__ import unicode_literals
|
|
|
|
from django.contrib.postgres.fields import ArrayField
|
|
|
|
from django.contrib.auth.models import User
|
|
|
|
from django.db import models
|
|
|
|
|
|
|
|
# Create your models here.
|
|
|
|
class Coin(models.Model):
|
|
|
|
name = models.CharField(max_length=4)
|
|
|
|
date = models.DateField()
|
|
|
|
priceusd = models.FloatField()
|
|
|
|
pricebtc = models.FloatField()
|
|
|
|
inflation = models.FloatField()
|
|
|
|
transactions = models.FloatField()
|
|
|
|
hashrate = models.FloatField()
|
|
|
|
stocktoflow = models.FloatField()
|
|
|
|
supply = models.FloatField()
|
|
|
|
fee = models.FloatField(default="0")
|
|
|
|
revenue = models.FloatField(default="0")
|
|
|
|
def __str__(self):
|
|
|
|
return self.priceusd
|
|
|
|
|
|
|
|
class Social(models.Model):
|
|
|
|
name = models.CharField(max_length=4)
|
|
|
|
date = models.DateField()
|
|
|
|
subscriberCount = models.IntegerField()
|
|
|
|
commentsPerHour = models.FloatField()
|
|
|
|
postsPerHour = models.FloatField()
|
|
|
|
|
|
|
|
def __str__(self):
|
|
|
|
return self.subscriberCount
|
|
|
|
|
|
|
|
class Dominance(models.Model):
|
|
|
|
name = models.CharField(max_length=4)
|
|
|
|
date = models.DateField()
|
|
|
|
dominance = models.FloatField()
|
|
|
|
|
|
|
|
def __str__(self):
|
|
|
|
return self.dominance
|
|
|
|
|
|
|
|
class Rank(models.Model):
|
|
|
|
name = models.CharField(max_length=4)
|
|
|
|
date = models.DateField()
|
|
|
|
rank = models.IntegerField()
|
|
|
|
|
|
|
|
def __str__(self):
|
2022-06-03 18:23:21 +00:00
|
|
|
return self.rank
|
|
|
|
|
|
|
|
class Sfmodel(models.Model):
|
|
|
|
date = models.DateField()
|
|
|
|
priceusd = models.FloatField()
|
|
|
|
color = models.FloatField()
|
|
|
|
stocktoflow = models.FloatField()
|
|
|
|
greyline = models.FloatField()
|
|
|
|
|
|
|
|
def __str__(self):
|
|
|
|
return self.date
|