forked from 0x2620/pandora
layer
This commit is contained in:
parent
da213d1745
commit
38d432bdd9
4 changed files with 10 additions and 3 deletions
|
@ -56,6 +56,9 @@ class Layer(models.Model):
|
|||
def json(self):
|
||||
return {'id': self.name, 'title': self.title, 'type': self.type}
|
||||
|
||||
def __unicode__(self):
|
||||
return self.title
|
||||
|
||||
class Annotation(models.Model):
|
||||
#FIXME: here having a item,start index would be good
|
||||
created = models.DateTimeField(auto_now_add=True)
|
||||
|
@ -78,3 +81,6 @@ class Annotation(models.Model):
|
|||
return True
|
||||
return False
|
||||
|
||||
def __unicode__(self):
|
||||
return "%s/%s-%s" %(self.item, self.start, self.stop)
|
||||
|
||||
|
|
|
@ -47,7 +47,7 @@ def siteJson():
|
|||
r['findKeys'].append(f)
|
||||
|
||||
r['groups'] = [p.name for p in Property.objects.filter(group=True)]
|
||||
r['layers'] = [l.json() for l in Layer.objects()]
|
||||
r['layers'] = [l.json() for l in Layer.objects.all()]
|
||||
|
||||
r['itemViews'] = [
|
||||
{"id": "info", "title": "Info"},
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
# vi:si:et:sw=4:sts=4:ts=4
|
||||
# Django settings for pandora project.
|
||||
# Django settings for pan.do/ra project defaults,
|
||||
# create local_settings.py to overwrite
|
||||
import os
|
||||
from os.path import join, normpath
|
||||
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
{% extends "admin/base.html" %}
|
||||
{% load i18n %}
|
||||
|
||||
{% block title %}{{ title }} | 0xdb.org{% endblock %}
|
||||
{% block title %}{{ title }} | pan.do/ra{% endblock %}
|
||||
|
||||
{% block branding %}
|
||||
<h1 id="site-name">0xdb.org</h1>
|
||||
|
|
Loading…
Reference in a new issue