summaryrefslogtreecommitdiff
path: root/server/queries/models.py
blob: d66fb55dc67c49fd4a926b42c4d0d5299cf80fbd (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
from django.db import models
from django.contrib import admin


class Sets(models.Model):
	name = models.CharField(max_length=100)
	hash = models.SlugField()
	keys = models.SlugField()
	values = models.SlugField()

	def __unicode__(self):
		return self.name

class QueryParameters(models.Model):
	key = models.CharField(max_length=100)
	value = models.CharField(max_length=100)

class StoredQuery(models.Model):
	set = models.CharField(max_length=100)
	parameters = models.ManytoManyField(QueryParameters)

	def __unicode__(self):
		return self.set



admin.site.register(StoredQuery)