summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGuillaume Seguin <guillaume@segu.in>2008-05-03 00:16:05 +0200
committerGuillaume Seguin <guillaume@segu.in>2008-05-03 00:16:05 +0200
commitc72a3b58c56944370b0bf117705082e164c3c47c (patch)
treefdcc688014717f73f9857115963dd557329213bf
parent972d7c6fb78a3fe794416fbcf1fd8381ff84d733 (diff)
downloadstocktrader-c72a3b58c56944370b0bf117705082e164c3c47c.tar.gz
stocktrader-c72a3b58c56944370b0bf117705082e164c3c47c.tar.bz2
* Ensure StockQuote's (index, place, short name) combinations are unique
-rw-r--r--main/models.py1
1 files changed, 1 insertions, 0 deletions
diff --git a/main/models.py b/main/models.py
index cb82c1e..251eff2 100644
--- a/main/models.py
+++ b/main/models.py
@@ -221,6 +221,7 @@ class StockQuote (models.Model):
class Meta:
verbose_name = _("quote")
verbose_name_plural = _("quotes")
+ unique_together = (("index", "place", "short_name"),)
def get_name (self):
if self.game_name: