summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGuillaume Seguin <guillaume@segu.in>2008-05-03 11:47:28 +0200
committerGuillaume Seguin <guillaume@segu.in>2008-05-03 11:47:28 +0200
commit40b0349d2fb06f9f9d200a119cf0405d2f495039 (patch)
tree4dffca34947fd717a5bf2dfe38767e7d4f050317
parentc72a3b58c56944370b0bf117705082e164c3c47c (diff)
downloadstocktrader-40b0349d2fb06f9f9d200a119cf0405d2f495039.tar.gz
stocktrader-40b0349d2fb06f9f9d200a119cf0405d2f495039.tar.bz2
* Add StockTeam model for future use
-rw-r--r--main/models.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/main/models.py b/main/models.py
index 251eff2..d6ad153 100644
--- a/main/models.py
+++ b/main/models.py
@@ -338,9 +338,16 @@ class StockQuoteLog (models.Model):
verbose_name = _("quote value log")
verbose_name_plural = _("quote value logs")
+class StockTeam (models.Model):
+ '''Team object'''
+ name = models.CharField (_("Team name"), max_length = 6)
+ founder = models.ForeignKey ('StockPlayer', unique = True,
+ verbose_name = _("Founder"))
+
class StockPlayer (models.Model):
'''Player object'''
user = models.ForeignKey (User, unique = True, verbose_name = _("User"))
+ team = models.ForeignKey (StockTeam, verbose_name = _("Team"))
usd = models.FloatField (_("Current amount of USD"))
eur = models.FloatField (_("Current amount of EUR"))
gbp = models.FloatField (_("Current amount of GBP"))