My question is as follows, in my application I have a Profile template that has the following fields:
Models.py:
class Perfil(models.Model):
nome = models.CharField(max_length=255, null=False)
pontuacao_total = models.FloatField(max_length=4, default=0)
pontuacao_ultima = models.FloatField(max_length=4, default=0)
In this application, there will be several rounds of plays, in this modeling, each round will have its score associated with the field pontuacao_ultima
, and pontuacao_total
will be the sum of these scores.
For example:
Round 1: 10 points
Round 2: 15 points
In this case, pontuacao_ultima
will be equal to 15 and pontuacao_total
equal to 25.
But in this way of approaching the situation there is a big problem that is the loss of data, I will only have stored the total and last scores of each player.
So I wanted to ask for a suggestion for some solution in this case, what can I do to not lose this data? For what I researched, there is no possibility of a template field being a list that would store the value of each round ...
Can anyone give me a light?