I have the following model in my django app:
class Budget_Vendite(models.Model):
product=models.ForeignKey()
byproduct=models.ForeignKey()
quant_jan=models.DecimalField()
quant_feb=models.DecimalField()
quant_mar=models.DecimalField()
price_jan=models.DecimalField()
price_feb=models.DecimalField()
price_mar=models.DecimalField()
I want to create a dataset that for each byproduct figure out the montly amount given by quant_jan*price_jan
Ad example:
byproduct | jan | feb |
byproduct_1 | quant_jan*price_jan | quant_feb*price_feb |